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
[user] | |
name = Joran Kikke | |
email = [email protected] | |
[github] | |
user = dangerousbeans | |
[core] | |
autocrlf = input | |
safecrlf = true | |
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
itinerary.lodgings.readonly(false).find(params[:id]) |
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
git ls-files --deleted | xargs git rm |
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
# clear and rebuild a rails app database (with bulk load rake task) | |
alias brails='rake db:drop && rake db:create:all && rake db:migrate && rake db:seed:load && rake db:seed' |
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
1 - "Is this the Aladdin Soundtrack?" | |
2 - "Should we go and eat Mexican over lunch? I heard it was really close by." | |
3 - "Trams" | |
(related) | |
3.1 - "Edinburgh Apple Store" |
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
FILE=`date +"%Y%m%d"`_backup.sql | |
DBSERVER=127.0.0.1 | |
DATABASE= | |
USER=postgres | |
PASS= | |
# (2) in case you run this twice in one day, remove the previous version of the file | |
unalias rm 2> /dev/null | |
rm ${FILE} 2> /dev/null | |
rm ${FILE}.gz 2> /dev/null |
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
dropdb -h localhost metadata_staging -U postgres && createdb -h localhost -U postgres metadata_staging && pg_dump -h test.dpluse.net metadata_staging && psql metadata_staging postgres < metadata_staging.sql |
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
-- What roles have access to which attributes on the given entity | |
SELECT r.name, a.name | |
FROM meta_attribute_roles ar | |
JOIN roles r on ar.role_id = r.id | |
JOIN meta_attributes a ON ar.meta_attribute_id = a.id | |
JOIN meta_entities e ON a.meta_entity_id = e.id | |
WHERE e.name like '%festival%'; |
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
export CLICOLOR=1 | |
export LSCOLORS=ExFxCxDxBxegedabagacad | |
# MacPorts Installer addition on 2011-05-12_at_15:42:16: adding an appropriate PATH variable for use with MacPorts. | |
export PATH=/opt/local/bin:/opt/local/sbin:$PATH | |
# Finished adapting your PATH environment variable for use with MacPorts. | |
export PGDATA=/usr/local/pgsql/data | |
export PATH=${PATH}:/usr/local/pgsql/bin |
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
# Find any files modified recently (4 days ago) | |
find / -type f -mtime -4 -exec ls -al {} \; | |
# Show detailed information about wtf a process is doing, 1234 = PID | |
lsof -p 1234 |
OlderNewer