Want to create a Gist from your editor, the command line, or the Services menu? Here's how.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
######################################################################################## | |
# Process Configuration File | |
# | |
# First, open the file and apply a file handle. | |
# Second, take the next record and store in a variable | |
# Third, chomp to remove the newline | |
# Fourth, split the line on the separator (change if needed) and store in variables | |
######################################################################################## | |
open(CONFIG, "./myfile.config"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use Net::SMTP; | |
$smtp = Net::SMTP->new('here.com'); # connect to an SMTP server | |
$smtp->mail( 'user\@here.com' ); # use the sender's address here | |
$smtp->to('user\@there.com'); # recipient's address | |
$smtp->data(); # Start the mail | |
# Send the header. | |
$smtp->datasend("To: user\@there.com\n"); | |
$smtp->datasend("From: user\@here.com\n"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$host = 'localhost'; /* Set to location of mysql server */ | |
$dbname = 'database_name'; | |
$user = 'user_name'; | |
$pwd = 'password'; | |
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Some code for creating timestamps | |
@months = qw(01 02 03 04 05 06 07 08 09 10 11 12); | |
@weekDays = qw(01 02 03 04 05 06 07); | |
($second, $minute, $hour, $dayOfMonth, $month, $yearOffset, $dayOfWeek, $dayOfYear, $daylightSavings) = localtime(); | |
$year = 1900 + $yearOffset; | |
$theTime = "$hour:$minute:$second, $weekDays[$dayOfWeek] $months[$month] $dayOfMonth, $year"; | |
if ( $dayOfMonth > 9 ) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
use strict; | |
use warnings; | |
###################################################################################### | |
# Script: count.pl | |
# Author: Jefferson Kirkland | |
# | |
# Description: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
header('HTTP/1.1 403 Forbidden'); | |
?> | |
<html> | |
<head> | |
<title>Congratulations! You have been DENIED access</title> | |
</head> | |
<body> | |
<font size="4">You have been denied access because of the following reasons:<br /><br /> | |
1.) Too many failed login attempts, so you are likely brute forcing through logins.<br /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#color and git branch | |
parse_git_branch() {·· | |
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/(\1)/' | |
} | |
export CLICOLOR=1 | |
export GREP_OPTIONS="--color" | |
export LSCOLORS=gxfxcxdxbxegedabagacad | |
PS1='\n\[\e[1;36m\]\w \[\e[m\]\[\e[1;33m\]$(parse_git_branch)\[\e[m\] \n> ' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This list includes beginner, intermediate and advanced ideas for projects. Happy coding and learning! | |
- In the USA yo have the following currency options: | |
100 Dollars | |
50 Dollars | |
20 Dollars | |
10 Dollars | |
5 Dollars | |
1 Dollar ( the 2 Dollar bill is very rare, ignore it) | |
25 cents ( the 50 cent coin is rare, also ignore it) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Various Degree Curriculum For Online Learning: | |
Open Source Society - Path to self-taught Computer Science: https://github.com/open-source-society/computer-science-and-engineering | |
Open Source Data Science Masters: http://datasciencemasters.org/ | |
A Bachelor's Level Computer Science Curriculum: http://blog.agupieware.com/2014/05/online-learning-bachelors-level.html?showComment=1399602288548#c541541571334513499 | |
An Intensive Bachelor's Level Computer Science Program Curriculum: http://blog.agupieware.com/2014/06/online-learning-intensive-bachelors.html | |