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 | |
# VIDEO Conversion Tool | |
# Takes a source directory, and converts for the web into an output directory | |
# Arguments: src, dest | |
# Set the title of the source file | |
# for f in "${1%/}"/*.{mp4,m4v} | |
# do | |
# filename=$(basename "$f") |
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/bash | |
# Takes an icon PNG as an argument, uses sips (macOS) or convert (ImageMagick), makes a lot of icons! | |
input_file=$1 | |
sizes=(20 29 40 50 57 60 72 76 83.5 512) | |
scales=(1 2 3) | |
for size in "${sizes[@]}" | |
do | |
for scale in "${scales[@]}" |
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/bash | |
# | |
# Image renaming script, requires exiftool | |
for f in "${1%/}"/*.{jpg,jpeg} | |
do | |
if [ -f "$f" ] | |
then | |
echo "Preparing $f" | |
filename=$(basename "$f") |
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/bash | |
# | |
# Image renaming script, requires exiftool | |
for f in "${1%/}"/*.{jpg,jpeg} | |
do | |
if [ -f "$f" ] | |
then | |
echo "Preparing $f" | |
filename=$(basename "$f") |
We can make this file beautiful and searchable if this error is corrected: No commas found in this CSV file in line 0.
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
mr Marathi | |
bs Bosnian | |
ee_TG Ewe (Togo) | |
ms Malay | |
kam_KE Kamba (Kenya) | |
mt Maltese | |
ha Hausa | |
es_HN Spanish (Honduras) | |
ml_IN Malayalam (India) | |
ro_MD Romanian (Moldova) |
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
module VatCalc | |
def VatCalc.vat_rate | |
@vat_rate ||= BigDecimal.new('20') | |
end | |
def VatCalc.vat_rate=(value) | |
@vat_rate = BigDecimal.new(value.to_s) | |
end |
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
BEFORE = 0.25 # Percent commission before the limit | |
LIMIT = 50000 # The commission boundary | |
AFTER = 0.20 # Percent after the boundary | |
# The only number to change is this one! No spaces, dots or commas...! | |
total_price_including_commssion = 10000000 | |
# Warning - Do not use for bids over a £1,000,000 Hammer |
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
import Foundation | |
// Further Reading: | |
// https://technet.microsoft.com/en-us/library/aa258277(v=sql.80).aspx | |
// http://www.unicode.org/reports/tr35/tr35-31/tr35-dates.html#Date_Format_Patterns | |
// http://www.w3.org/TR/NOTE-datetime |
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 filter-branch --force --index-filter 'git rm --cached --ignore-unmatch FILE_TO_DELETE' --prune-empty --tag-name-filter cat -- --all |
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/bash | |
hdiutil create -fs HFS+ -srcfolder "$1" -volname "$(basename $1)" "$1.dmg" | |
tar -cjf "$1.tar.bz2" -C "$(dirname $1)" "$(basename $1)" |
OlderNewer