Skip to content

Instantly share code, notes, and snippets.

Avatar

Jerzy J. Gangi jerzygangi

View GitHub Profile
@abn
abn / heredoc-dockerfile.snip
Last active Jul 26, 2020
Dockerfile alternatives for heredoc
View heredoc-dockerfile.snip
#printf
RUN printf '#!/bin/bash\n\
echo hello world from line 1\n\
echo hello world from line 2'\
>> /tmp/hello
#echo
RUN echo -e '#!/bin/bash\n\
echo hello world from line 1\n\
echo hello world from line 2'\
@adamjmurray
adamjmurray / gist:3154437
Created Jul 21, 2012
Managing Ruby gems programmatically
View gist:3154437
# Environment, set GEM_HOME & GEM_PATH. For example, we can launch JRuby like this:
# GEM_HOME=/Users/amurray/tmp/gems/ GEM_PATH=/Users/amurray/tmp/gems java -jar ~/Downloads/jruby-complete-1.7.0.preview1.jar -S irb
# =====================
# LISTING gems
puts Gem::Specification.find_all.to_s
puts Gem::Specification.find_all.map{|spec| "#{spec.name} (#{spec.version})" }
# =====================
# USING (a specific version of) gems
You can’t perform that action at this time.