gitflow | git |
---|---|
git flow init |
git init |
git commit --allow-empty -m "Initial commit" |
|
git checkout -b develop master |
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
" Vim plugin to highlight variables in Perl. | |
" I now created a repository from this: https://github.com/mannih/vim-perl-variable-highlighter | |
function! s:hlvar() | |
if ( exists( "w:current_match" ) ) | |
call matchdelete( w:current_match ) | |
unlet w:current_match | |
endif | |
let l:old_iskeyword = &iskeyword |
Check if your Perl stack is vulnerable to the OpenSSL « heartbleed » bug.
curl -s https://gist.githubusercontent.com/dolmen/10096474/raw/ssl-heartbleed-check.pl | perl
When the directory structure of your Node.js application (not library!) has some depth, you end up with a lot of annoying relative paths in your require calls like:
const Article = require('../../../../app/models/article');
Those suck for maintenance and they're ugly.
Locate the section for your github remote in the .git/config
file. It looks like this:
[remote "origin"]
fetch = +refs/heads/*:refs/remotes/origin/*
url = [email protected]:joyent/node.git
Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/*
to this section. Obviously, change the github url to match your project's URL. It ends up looking like this:
- Create the version 1 tables in a postgres schema, then create DBIC classes with
dbicdump.sh
- run
./gen_migration.pl 1
- Drop tables, and create version 2 tables from
db.sql
- run
./gen_migration.pl 2
- Check
sql/PostgreSQL/upgrade/1-2/001-auto.sql
- Should drop the
test_pkey
CONSTRAINT properly (need this for now: https://github.com/dbsrgits/sql-translator/pull/20/files)
- Should drop the
- Should know to add the new PRIMARY KEY on
test
table before adding the FOREIGN KEY totest2
table
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/env perl | |
# parks - spark clone in perl (https://github.com/holman/spark) | |
# Alternatives: https://github.com/holman/spark/wiki/Alternative-Implementations | |
# Wicked Cool Examples: https://github.com/holman/spark/wiki/Wicked-Cool-Usage | |
use List::Util qw( min max ); local $/; | |
my ($t, @n) = ( [qw(▁ ▂ ▃ ▄ ▅ ▆ ▇ █)], -t STDIN ? @ARGV : split ' ', <STDIN> ); | |
print map($t->[ int( ( $_ - min(@n) ) / max(@n) * $#$t ) ], @n), "\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
#!/usr/bin/perl | |
use strict; | |
use warnings; | |
use lib qw(./lib); | |
use HTTP::Request; | |
use IO::Lambda qw(:lambda); | |
use IO::Lambda::HTTP qw(http_request); | |
use Time::HiRes qw(time); | |
my @urls = ( |
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
#!/bin/sh | |
# | |
# some_website - this script starts and stops some_website | |
# | |
# chkconfig: - 85 15 | |
# description: Some website description | |
# pidfile: /var/run/plackup.some_website.pid | |
PID=/var/run/plackup.some_website.pid |
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
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE | |
Version 2, December 2004 | |
Copyright (C) 2011 Mathieu 'p01' Henri - http://www.p01.org/releases/ | |
Everyone is permitted to copy and distribute verbatim or modified | |
copies of this license document, and changing it is allowed as long | |
as the name is changed. | |
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE |
NewerOlder