This file contains hidden or 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
a={{a}} | |
b={{b}} | |
c={{c}} | |
d={{d}} | |
e={{e}} |
This file contains hidden or 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
mpapis@niczsoft:~/projects/opensource> test_f(){ | |
> echo 'a' | |
> } | |
mpapis@niczsoft:~/projects/opensource> test_f | |
a | |
mpapis@niczsoft:~/projects/opensource> which test_f | |
which: no test_f in (/home/mpapis/.rvm/gems/ruby-1.9.2-p180/bin:/home/mpapis/.rvm/gems/ruby-1.9.2-p180@global/bin:/home/mpapis/.rvm/rubies/ruby-1.9.2-p180/bin:/home/mpapis/.rvm/bin:/usr/local/bdsm/pkg/active/bin:/home/mpapis/bin:/usr/local/bin:/usr/bin:/bin:/usr/bin/X11:/usr/X11R6/bin:/usr/games:/usr/sbin:/usr/sbin) | |
mpapis@niczsoft:~/projects/opensource> type test_f | head -1 | |
test_f is a function | |
mpapis@niczsoft:~/projects/opensource> command -v test_f ; echo $? |
This file contains hidden or 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
mpapis@niczsoft:~/projects/opensource/rubygems-bundler> gem build rubygems-bundler.gemspec --backtrace | |
ERROR: While executing gem ... (NoMethodError) | |
undefined method `write' for #<Syck::Emitter:0x818f710> | |
/home/mpapis/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/psych/visitors/emitter.rb:17:in `end_document' | |
/home/mpapis/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/psych/visitors/emitter.rb:17:in `visit_Psych_Nodes_Document' | |
/home/mpapis/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/psych/visitors/visitor.rb:10:in `accept' | |
/home/mpapis/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/psych/visitors/emitter.rb:10:in `block in visit_Psych_Nodes_Stream' | |
/home/mpapis/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/psych/visitors/emitter.rb:10:in `each' | |
/home/mpapis/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/psych/visitors/emitter.rb:10:in `visit_Psych_Nodes_Stream' | |
/home/mpapis/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/psych/visitors/visitor.rb:11:in `accept' |
This file contains hidden or 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
extensions/core/core/actions | |
extensions/core/core/modules | |
extensions/core/ext/actions | |
extensions/core/ext/modules | |
extensions/internal/ <- bdsm-extensions | |
extensions/external/backup <- github/mpapis/bdsm_backup |
This file contains hidden or 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
mpapis@niczsoft:~/projects/opensource/bdsm> sudo bdsm --debug extend mpapis/bdsm_backup backup | |
root's password: | |
DEBUG: on | |
DEBUG: detected path:/usr/local/bdsm/extensions/builtin/core/actions/ext/extend, action:default, params:mpapis/bdsm_backup backup. | |
DEBUG: WTF!!! move code to actions | |
scm_get mpapis/bdsm_backup -> /usr/local/bdsm/src/extensions/mpapis_bdsm_backup | |
- backup | |
mpapis@niczsoft:~/projects/opensource/bdsm> bdsm list | |
Extensions installed in /usr/local/bdsm/extensions/external: | |
backup |
This file contains hidden or 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
ruby-1.8.7-p334 :001 > rvm_path = File.dirname(File.dirname(ENV['MY_RUBY_HOME'])) | |
=> "/home/mpapis/.rvm" | |
ruby-1.8.7-p334 :002 > rvm_lib_path = File.join(rvm_path, 'lib') | |
=> "/home/mpapis/.rvm/lib" | |
ruby-1.8.7-p334 :003 > $LOAD_PATH.unshift rvm_lib_path | |
=> ["/home/mpapis/.rvm/lib", "/home/mpapis/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/site_ruby/1.8", "/home/mpapis/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/site_ruby/1.8/i686-linux", "/home/mpapis/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/site_ruby", "/home/mpapis/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/vendor_ruby/1.8", "/home/mpapis/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/vendor_ruby/1.8/i686-linux", "/home/mpapis/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/vendor_ruby", "/home/mpapis/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8", "/home/mpapis/.rvm/rubies/ruby-1.8.7-p334/lib/ruby/1.8/i686-linux", "."] | |
ruby-1.8.7-p334 :004 > RVM.current | |
NameError: uninitialized constant RVM | |
from (irb):4 | |
ruby-1.8.7-p334 :005 > require 'rvm' |
This file contains hidden or 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
a='' | |
case "${a:-n}" in | |
(y|yes) echo "true" | |
;; | |
(n|no) echo "false" | |
;; | |
(*) echo "else" | |
;; | |
esac |
This file contains hidden or 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 bash | |
export LEVEL=0 | |
function log() { | |
printf "%$(( LEVEL * 2 ))s$*\n" "" | |
} | |
function fail() { | |
local ret=$1 |
This file contains hidden or 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 bdsm | |
module_or_error "backup/scripting" \ | |
"backup extension not available, install it with: bdsm extend mpapis/bdsm_backup as backup" | |
backup_dir ~/tmp/test | |
log "Check https://github.com/mpapis/bdsm_backup for instructions" |
OlderNewer