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 python3 | |
# -*- coding: utf-8 -*- | |
# | |
# Updated to use Python 3 by Malcolm Greaves. | |
# | |
# Python script to find the largest files in a git repository. | |
# The general method is based on the script in this blog post: | |
# http://stubbisms.wordpress.com/2009/07/10/git-script-to-show-largest-pack-objects-and-trim-your-waist-line/ | |
# | |
# The above script worked for me, but was very slow on my 11GB repository. This version has a bunch |
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
# WARNING. DO NOT USE tls_private_key resource like I have done in this example | |
# Doing so will result in the private key being stored in state. You do not want that | |
# Instead use an existing key pair and use the file interpolation function to source | |
# the private key from disk for use in the rsadecrypt interpolation function | |
resource "tls_private_key" "key" { | |
algorithm = "RSA" | |
} | |
resource "aws_key_pair" "key_pair" { |
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
namespace :db do | |
# Rake::Task['db:load_config'].enhance [:environment] | |
desc 'Truncate all tables' | |
task :truncate => :environment do | |
puts 'Truncating: ' | |
ActiveRecord::Base.connection.tables.each do |table| | |
unless %w(schema_migrations rails_admin_histories).include? table |