Skip to content

Instantly share code, notes, and snippets.

View bascht's full-sized avatar
📢
Setting all the statuses.

Sebastian Schulze bascht

📢
Setting all the statuses.
View GitHub Profile
irb(main):002:0> expression = /(?:OUT[=]*)/
=> /(?:OUT[=]*)/
irb(main):003:0> "OUT".match(expression)
=> #<MatchData "OUT">
irb(main):004:0> "OUT=".match(expression)
=> #<MatchData "OUT=">
irb(main):005:0> "Quark".match(expression)
=> nil
$ drush -d @myalias solr-index
Bootstrap to phase 0. [0 sec, 2.18 MB] [bootstrap]
Drush bootstrap phase : _drush_bootstrap_drush() [0.01 sec, 2.31 MB] [bootstrap]
Loaded alias @myalias from file /home/drupal/.drush/aliases.drushrc.php [0.01 sec, 2.32 MB] [notice]
Cache HIT cid: 5.10.0-commandfiles-0-afca815239e5d26eaa4f64880a91114b [0.02 sec, 2.33 MB] [debug]
Begin redispatch via invoke process [0.08 sec, 5.27 MB] [notice]
Backend invoke: ssh -o PasswordAuthentication=no myhost 'drush --invoke --debug [command]
--root=/var/www/current/drupal-cms/ --uri=www.myhost.com --verbose 2>&1' 2>&1 [0.16 sec, 5.28 MB]
executing ssh -o PasswordAuthentication=no myhost 'drush --invoke --debug [notice]
--root=/var/www/current/drupal-cms/ --uri=www.myhost.com --verbose 2>&1' 2>&1 [0.16 sec, 5.28 MB]
@bascht
bascht / Karnevalscomputerseminarpackliste.org
Created February 11, 2015 12:24
Karnevalscomputerseminarpackliste

Snacks

  • [ ] Beef Jerkey
  • [ ] Doppelkekse
  • [ ] Gummibärchen
  • [ ] Waffeln

Technik

  • [ ] AirPort Express
  • [ ] Kopfhörer
  • [ ] Ladegerät
  • [ ] Laptop
[alias]
lol= 'log' '--oneline' '--graph' '--decorate'
lg1 = log --graph --all --format=format:'%C(bold blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(bold white)— %an%C(reset)%C(bold yellow)%d%C(reset)' --abbrev-commit --date=relative
lg2 = log --graph --all --format=format:'%C(bold blue)%h%C(reset) - %C(bold cyan)%aD%C(reset) %C(bold green)(%ar)%C(reset)%C(bold yellow)%d%C(reset)%n'' %C(white)%s%C(reset) %C(bold white)— %an%C(reset)' --abbrev-commit
log= 'log' '--decorate' '--pretty=full'
me = $GIT_AUTHOR_NAME
lg = log --pretty=format:'%Cred%h%Creset - %Cgreen(%cr)%Creset%C(yellow)%d%Creset %s %C(bold blue)<%an>%Creset' --abbrev-commit --graph
lg-me = !git lg --author=\"$GIT_AUTHOR_NAME\"
today-all = !git lg --all --since='12am'
lg-day = "!f() { git lg-me --all --after=\"${1-(date \"+%Y-%m-%d\")} 00:00\" --before=\"${1-(date \"+%Y-%m-%d\")} 23:59\"; }; f"
Lorem ipsum dolor sit amet, consectetur adi|piscing elit.
; jump from here --------------------------^
Lorem ipsum dolor sit amet, consectetur| adipiscing elit.
; to here -----------------------------^
@bascht
bascht / foo.yml
Last active August 29, 2015 14:19
dings:
eins: &eins
some: property
zwei: &zwei
some: otherproperty
bums:
eins: *eins
zwei: *zwei
[24] pry(main)> first = "First"
=> "First"
[25] pry(main)> last = "Last"
=> "Last"
[26] pry(main)> name(first, last) {
[26] pry(main)* return `${first} ${last}`
[26] pry(main)* }
=> "First Last"
[1] pry(main)> def name(first, last, &blub)
[1] pry(main)* def return; end
[1] pry(main)* "#{first} #{last}"
[1] pry(main)* end
=> :name
def mount(folders)
folders.map do |name, options|
check_compatibility!
folder(name, options)
end
end
:eins:
:hostname: eins.blub.local
:box: my/customer/box-eins
:memory: 1536
:box_version: ' ~> 1.1.146'
:sync:
'first':
target: /var/www/some/files
'second':
target: /var/build