Skip to content

Instantly share code, notes, and snippets.

View Jorge-Cano's full-sized avatar
🎯
Focusing

JC Jorge-Cano

🎯
Focusing
View GitHub Profile
@Jorge-Cano
Jorge-Cano / README.md
Created November 22, 2017 22:41 — forked from shime/README.md
The Qlobe - by Yusuke Endoh

Qlobe

Qlobe is a fascinating example of quine in Ruby, submitted by a member of the Ruby core team - Yusuke Endoh.

Programs that output changed executable versions of themselves while managing to spin the globe and still remaining executable are cool, right?

To experience its magic, run the following

curl -fSSl https://gist.githubusercontent.com/shime/f0ebe84ca42c33b51d42/raw/5e74315dc6b6fe572f8a457536ad7eb17ad3f1e4/qlobe.rb > qlobe.rb; while true; do ruby qlobe.rb | tee temp.rb; sleep 1; mv -f temp.rb qlobe.rb; done
@Jorge-Cano
Jorge-Cano / chat.rb
Created November 14, 2017 07:16 — forked from rkh/chat.rb
Simple Chat Application using the Sinatra Streaming API
# coding: utf-8
require 'sinatra'
set server: 'thin', connections: []
get '/' do
halt erb(:login) unless params[:user]
erb :chat, locals: { user: params[:user].gsub(/\W/, '') }
end
get '/stream', provides: 'text/event-stream' do
@Jorge-Cano
Jorge-Cano / index.html
Created February 26, 2017 03:20
ELK Web Design // source http://jsbin.com/setusos
<!DOCTYPE html>
<html>
<head>
<title>ELK Web Design</title>
<link rel="stylesheet" type="text/css" href="css/style.css">
<style id="jsbin-css">
body {
color: black;
font-size: 18px;
font-family: Arial;