Skip to content

Instantly share code, notes, and snippets.

View klappradla's full-sized avatar

Max Mulatz klappradla

View GitHub Profile
@traumverloren
traumverloren / custom-terminal-greetings.md
Last active March 16, 2018 18:38
custom-terminal-greetings

Something cheery and motivating for your terminal ʕᵔᴥᵔʔ

Add this to your .zshrc or .bash_profile:

# Nice Greetings
niceThings=('you look lovely today' 'you are so smart' 'I think you are fantastic' 'You are super creative' 'You can do anything' 'You write KICKASS code' 'Your hair looks amazing today' 'You inspire soooo many people' 'You are a strong powerful woman');

emojis=('ʕᵔᴥᵔʔ' '(。◕‿◕。)' '( ˘ ³˘)♥' 'ฅ^•ﻌ•^ฅ' '(づ ̄ ³ ̄)づ' '┌(ㆆ㉨ㆆ)ʃ' '“ヽ(´▽`)ノ”' '♥‿♥' 'ᕕ( ᐛ )ᕗ' '(ᵔᴥᵔ)')
begin
require "bundler/inline"
rescue LoadError => e
$stderr.puts "Bundler version 1.10 or later is required. Please update your Bundler"
raise e
end
gemfile(true) do
source "https://rubygems.org"
@mdo
mdo / 00-intro.md
Last active November 15, 2024 14:13
Instructions for how to affix an Ikea Gerton table top to the Ikea Bekant sit-stand desk frame.

Ikea Bekant standing desk with Gerton table top

@andreibosco
andreibosco / creative-cloud-disable.md
Last active August 29, 2024 03:27
disable creative cloud startup on mac
@JPvRiel
JPvRiel / bash_replace_newlines_string_substitution.md
Last active August 19, 2024 23:54
Replacing newlines with commas (or other text) using pure bash string substitution (not awk).

In this example

  • Multiline input can be caputured by spreading openening and closing quote accross lines
  • Newlines can be replaced using built-in bash text substitution
  • The main trick is knowing that $'\n' is the way to specify the newling within the subsitution
  • Note, echo output of a var without quotation replaces newlines with spaces
$ t='1
> 2
@ryyppy
ryyppy / proposal.md
Last active May 20, 2023 02:07
A Life on a Commandline - How to never touch a mouse again. Lightning Talk Proposal for ReactiveConf 2016 (https://reactiveconf.com/)

Proposal for this year's Reactive lightning talks @ReactiveConf - If you want to see my talk, star this gist please :-) [Reactive Blogpost][reactive-conference-blogpost]


A life on a Commandline

As a JavaScript developer, could you imagine using something else than Atom, Sublime or other IDE-like text-editors? During their daily work, people wrangle a lot with different applications, editors, windows, browsers and loose a lot of time because of their tools getting in their way.

begin
require 'bundler/inline'
rescue LoadError => e
$stderr.puts 'Bundler version 1.10 or later is required. Please update your Bundler'
raise e
end
gemfile(true) do
source 'https://rubygems.org'
gem 'rails', '5.0.0.beta3'
@ctechols
ctechols / compinit.zsh
Last active November 13, 2024 23:55
Speed up zsh compinit by only checking cache once a day.
# On slow systems, checking the cached .zcompdump file to see if it must be
# regenerated adds a noticable delay to zsh startup. This little hack restricts
# it to once a day. It should be pasted into your own completion file.
#
# The globbing is a little complicated here:
# - '#q' is an explicit glob qualifier that makes globbing work within zsh's [[ ]] construct.
# - 'N' makes the glob pattern evaluate to nothing when it doesn't match (rather than throw a globbing error)
# - '.' matches "regular files"
# - 'mh+24' matches files (or directories or whatever) that are older than 24 hours.
autoload -Uz compinit
@einfallstoll
einfallstoll / README.md
Created June 30, 2015 13:30
Reset Spotlight Location (Fix for OS X 10.11 El Capitan)

Installation for GUI Users

  1. Right click the file and choose information and choose to always open this file with Terminal.app

  2. Go to the Terminal.app and do something like this chmod 744 Reset Spotlight.sh

  3. There you go, you can now double click it so reset the Spotlight location

  4. Optional: Uncomment line for the useCount to prevent Spotlight to forget that you already used it

@klappradla
klappradla / lame.sh
Last active December 10, 2022 20:02
Using lame command line tool (e.g. convert flac to mp3
# Convert .flac to .mp3 (lossless)
for f in *.flac; do ffmpeg -i "$f" -aq 1 "${f%flac}mp3"; done
# Convert .flac to .mp3, compress to ~ 120k
for f in *.flac; do ffmpeg -i "$f" -aq 5 "${f%flac}mp3"; done
# Convert .flac to mp3, compress to ~ 128k
for f in *.flac; do ffmpeg -i "$f" -b:a 128k "${f%flac}mp3"; done
# Convert .flac to mp3, compress to variable 190k