Skip to content

Instantly share code, notes, and snippets.

@togume
togume / access_to_mysql.sh
Created Nov 5, 2017
Shell script to convert Access DB to SQL - Requires mdbtools
View access_to_mysql.sh
#!/bin/bash
TABLES=$(mdb-tables -1 $1)
for t in $TABLES
do
echo "DROP TABLE IF EXISTS $t;"
done
mdb-schema $1 mysql
for t in $TABLES
View socks_proxy.sh
#!/bin/bash
# This script sets up the SOCKS proxy using AppleScript commands to set up the proxy
# settings, establishes an SSH SOCKS tunnel, and removes the proxy once the session
# ends, or script exits.
ssh_port=9999
echo -e "\nChoose SSH Host:"
select CHOICE in iPhone aws msm Exit
do
View gist:d606a4bcb042ad5f3c53
name,hotel_id,street,city,state,post_code,country,continent,rating,star_class,review_count,rooms,type,market_name,market_rank,market_size,market_url,recommended,url,subratings,subratings_cat,description,highlights,price_range,review_count_details,review_count_details_cat
Landal Aelderholt,7972564,Aelderholt 4,Aalden,Drenthe Province,7854 TZ,The Netherlands,Europe,,,1,,Cottage,Specialty Lodging in Aalden,1,1,http://www.tripadvisor.com/Hotels-g7982012-c3-Aalden_Drenthe_Province-Hotels.html,,http://www.tripadvisor.com/Hotel_Review-g7982012-d7972564-Reviews-Landal_Aelderholt-Aalden_Drenthe_Province.html,,,,,,,
@togume
togume / slicing_saas_pie.md
Last active Aug 29, 2015
Slicing Pie with Mike Moyer - Existing, Monolithic SAAS Company
View slicing_saas_pie.md
  • Starting point

    • Company A is a monolythic SAAS company built over the last ~15 years which is looking to improve their solution - it's bleeding customers and does not have the leadership, funds, or skills to take on the task
    • Company B is a new venture which will Slice Pie in the traditional way
  • Company A

    • Main sources of value:
      • Existing customer base/revenue stream
      • Business process/concept/solution/lessons-learned (what they've figured out during the lifetime of the venture)
    • Owned by shareholders
    • Legacy product
@togume
togume / gist:10594736
Created Apr 13, 2014
Node Behind Nginx Chef Template and Recipe Call
View gist:10594736
# Recipe Call
template "#{node[:nginx][:dir]}/sites-available/<app_name>" do
source "nginx_node_app.erb"
owner "root"
group "root"
mode 0644
variables(
:app_name => "<app_name>",
:app_port => "<app_port>",
:app_domains => "<app_domains>"
@togume
togume / gist:6301520
Created Aug 21, 2013
Verbose output of _brew upgrade vim_
View gist:6301520
[togume:~] $ brew upgrade vim -v
==> Upgrading 1 outdated package, with result:
vim 7.4
==> Upgrading vim
rm /usr/local/bin/xxd
rm /usr/local/bin/vimtutor
rm /usr/local/bin/vimdiff
rm /usr/local/bin/vim
rm /usr/local/bin/view
rm /usr/local/bin/rvim