- Some must-have scripts
/script install buffers.pl buffer_autoclose.py iset.pl go.py colorize_nicks.py
| blueprint: | |
| name: Winter Heating Control | |
| description: Control your heating with options for person home, if temp is below a specific value, set temp, and heating between specific times. | |
| domain: automation | |
| input: | |
| heating: | |
| name: Climate Device | |
| description: The climate device to use. | |
| selector: | |
| entity: |
| """ | |
| Exports issues from a list of repositories to individual csv files. | |
| Uses basic authentication (Github username + password) to retrieve issues | |
| from a repository that username has access to. Supports Github API v3. | |
| Forked from: unbracketed/export_repo_issues_to_csv.py | |
| """ | |
| import argparse | |
| import csv | |
| from getpass import getpass | |
| import requests |
| # requires: 256 color terminal | |
| /script install iset.pl | |
| /script install buffers.pl | |
| /script install colorize_nicks.py | |
| /set weechat.look.buffer_notify_default message | |
| /set weechat.look.color_nick_offline on | |
| /set weechat.look.prefix_action " •" | |
| /set weechat.look.prefix_join "▬▶" |
| #!/bin/bash | |
| # A script to set up a new mac. Uses bash, homebrew, etc. | |
| # Focused for ruby/rails development. Includes many utilities and apps: | |
| # - homebrew, rvm, node | |
| # - quicklook plugins, terminal fonts | |
| # - browsers: chrome, firefox | |
| # - dev: iterm2, sublime text, postgres, chrome devtools, etc. | |
| # - team: slack, dropbox, google drive, skype, etc |
| UseCanonicalName Off | |
| <VirtualHost *:80> | |
| ServerAdmin [email protected] | |
| ServerAlias *.example.com | |
| VirtualDocumentRoot /var/www/%1/public | |
| DirectoryIndex index.php index.htm index.html | |
| <Directory /var/www/*/public/> | |
| AllowOverride All | |
| </Directory> |
| // Use Gists to store code you would like to remember later on | |
| console.log(window); // log the "window" object to the console |
| # convert multipage pdf to single page tiff | |
| gs -q -dNOPAUSE -dBATCH -sDEVICE=tiffg4 -sOutputFile=%04d.tif source.pdf -c qui | |
| # or use -sDEVICE=pgmraw to convert to pgm | |
| # unpaper, rotate the logical page 90 degrees, each logical page contained two scanned physical pages, so we use --layout double (for input) and --output-pages 2 since we want to split these two pages. | |
| unpaper -v --deskew-scan-deviation 3.0 --border-align top --deskew-scan-range 15 --no-grayfilter --no-blurfilter --no-noisefilter --overwrite --pre-rotate 90 --border-scan-step 4 --layout double --output-pages 2 %04d.pgm.pbm unpaper%04d.pbm | |
| # trim the pages and convert the to single-page pdfs | |
| find . -name 'unpaper*' | xargs -i -n1 -P6 convert -trim +repage {} {}.pdf |