Get Homebrew installed on your mac if you don't already have it
Install highlight. "brew install highlight". (This brings down Lua and Boost as well)
#!/bin/bash | |
# | |
# Open new Terminal tabs from the command line | |
# | |
# Author: Justin Hileman (http://justinhileman.com) | |
# | |
# Installation: | |
# Add the following function to your `.bashrc` or `.bash_profile`, | |
# or save it somewhere (e.g. `~/.tab.bash`) and source it in `.bashrc` | |
# |
namespace :ec2 do | |
# setup chef config | |
# | |
config = File.join(File.dirname(__FILE__), '..', '.chef', 'knife.rb') | |
Chef::Config.from_file(config) | |
load_gem_or_report(%w{aws}) | |
desc 'Delete any ec2-based chef nodes that no longer exist' | |
task :cleanup_nodes do |
Get Homebrew installed on your mac if you don't already have it
Install highlight. "brew install highlight". (This brings down Lua and Boost as well)
#!/usr/bin/ruby | |
require 'rubygems' | |
require 'hipchat-api' | |
require 'getopt/long' | |
require 'socket' | |
require 'erb' | |
#Do not modify these constants! (after you set these up, of course) | |
HipApiKey='ABCDEFGHKJHKJHKJHKJH' | |
Room='Nagios' |
When you do your first Sonar run on your project, you get a lot of new quality numbers to play with, but no trends. You only have one data set for comparison, the now picture.
Wouldn't it be nice if you could see the current trend of the project without waiting a couple of month for the 'daily/weekly' Sonar runs to fill up the data? Well, you're in luck! And if you're using git as a version system as well, this is your day. :)
In the Sonar Advanced Parameter documentation you will find a System Property called sonar.projectDate. The property let you tell Sonar when in time the running analysis was ran.
By combining this property and what your version system does best, track changes to source, we can now play back the history of the project as far as Sonar is concerned.
This little Bash script illustrates the concept. To spell out what it does in human readable form:
C: | |
cd %WINDIR%\Microsoft.NET\Framework\ | |
for /d %%D IN (*) DO .\%%D\ngen.exe executeQueuedItems | |
cd %WINDIR%\Microsoft.NET\Framework64\ | |
for /d %%D IN (*) DO .\%%D\ngen.exe executeQueuedItems | |
pause |
data:text/html, <style type="text/css">#e{position:absolute;top:0;right:0;bottom:0;left:0;}</style><div id="e"></div><script src="http://d1n0x3qji82z53.cloudfront.net/src-min-noconflict/ace.js" type="text/javascript" charset="utf-8"></script><script>var e=ace.edit("e");e.setTheme("ace/theme/monokai");e.getSession().setMode("ace/mode/ruby");</script> |
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000
<powershell> | |
# First we add our administrative user, replace username and password with your own | |
$computer=$env:ComputerName | |
$user="username" ## Change this! | |
$password='password' ## And change this too! | |
$objOu = [ADSI]"WinNT://$computer" | |
$objGroup = [ADSI]"WinNT://$computer/Administrators,group" | |
$objUser = $objOU.Create("User", $user) | |
$objUser.setpassword($password) |
# applescript | |
# add login item | |
osascript -e 'tell application "System Events" to make login item at end with properties {name: "Notes",path:"/Applications/Notes.app", hidden:false}' | |
# delete login item | |
osascript -e 'tell application "System Events" to delete login item "itemname"' | |
# list loginitems | |
osascript -e 'tell application "System Events" to get the name of every login item' |