Skip to content

Instantly share code, notes, and snippets.

Jordano Moscoso Xosmond

Block or report user

Report or block Xosmond

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
Xosmond / remote_sudo.rb
Created Dec 8, 2017 — forked from ainoya/remote_sudo.rb
Execute remote sudo command with net-ssh
View remote_sudo.rb
#!/usr/bin/env ruby
require 'net/ssh'
require 'highline/import'
def get_password
ask( "Enter Password: " ) {|q| q.echo = '*'}
def remote_sudo host, ssh_user, command, opts={}
View download_zip.rb
def download_zip(image_list)
unless image_list.blank?
file_name = ''
stringio = Zip::ZipOutputStream::write_buffer do |z|
z.put_next_entry("empty_folder/") ## Create a folder
image_list.each do |img|
title = img.title
title += '.jpg' unless title.end_with?('.jpg')
Xosmond /
Created Aug 31, 2017 — forked from ziadoz/
Install Chrome, ChromeDriver and Selenium on Ubuntu 16.04
#!/usr/bin/env bash
# Versions
Xosmond / rspec_rails_cheetsheet.rb
Created Jul 20, 2017 — forked from them0nk/rspec_rails_cheetsheet.rb
Rspec Rails cheatsheet (include capybara matchers)
View rspec_rails_cheetsheet.rb
@user.should have(1).error_on(:username) # Checks whether there is an error in username
@user.errors[:username].should include("can't be blank") # check for the error message
response.should render_template(:index)
response.should redirect_to(movies_path)
Xosmond / Vultr-add-dockercompose
Last active Mar 31, 2017 — forked from dmp1ce/vultr-ubuntu-15.04-configure
Configure Ubuntu 15.04 for docker-compose and decompose on
View Vultr-add-dockercompose
# To run from shell:
# bash <(curl -sSL
do_config() {
# Make sure to run as root
user="$(id -un 2>/dev/null || true)"
if [ "$user" != 'root' ]; then
View capybara cheat sheet
=Clicking links and buttons=
click_link('Link Text')
click('Link Text') # Click either a link or a button
click('Button Value')
View SHODAN Filters
» city
» country
nginx city:"San Diego" country:US
» geo
Devices within a 50km radius of San Diego (32.8,-117): geo:32.8,-117,50
» hostname
"Server: gws" hostname:google
» net
» os
Xosmond /
Created Jul 2, 2016 — forked from kgrz/
Possible workaround for installing nokogiri 1.6.8 on OSX with brewed libxml2 2.9.4


The following commands fail on OSX:

gem install nokogiri
gem install nokogiri -- --use-system-libraries
gem install nokogiri -- --use-system-libraries --with-xslt-dir=/usr/local/opt/libxslt --with-xml2-dir=/usr/local/opt/libxml2


Xosmond / gist:0656fa5f378c007c3e0e1ce48fffb008
Created Jun 10, 2016 — forked from joho/gist:3735740
PostgreSQL 9.2 upgrade steps
View gist:0656fa5f378c007c3e0e1ce48fffb008
Steps to install and run PostgreSQL 9.2 using Homebrew (Mac OS X)
(if you aren't using version 9.1.5, change line 6 with the correct version)
1. launchctl unload -w ~/Library/LaunchAgents/homebrew.mxcl.postgresql.plist
2. mv /usr/local/var/postgres /usr/local/var/postgres91
3. brew update
4. brew upgrade postgresql
5. initdb /usr/local/var/postgres -E utf8
6. pg_upgrade -b /usr/local/Cellar/postgresql/9.1.5/bin -B /usr/local/Cellar/postgresql/9.2.0/bin -d /usr/local/var/postgres91 -D /usr/local/var/postgres
7. cp /usr/local/Cellar/postgresql/9.2.0/homebrew.mxcl.postgresql.plist ~/Library/LaunchAgents/
You can’t perform that action at this time.