Skip to content

Instantly share code, notes, and snippets.

View thapakazi's full-sized avatar
💭
🐧 🗡️ 💻

Milan Thapa thapakazi

💭
🐧 🗡️ 💻
View GitHub Profile
<table border="1" cellpadding="15" bgcolor="#fcfcfc" cellspacing="0" style="border-collapse: collapse" bordercolor="#DDDDDD" width="100%">
<tr bgcolor="#f1f1f1">
<td width="60%"><b>Subject</b></td>
<td width="10%"><div align="center"><b>Theory Marks</b></div></td>
<td width="10%"><div align="center"><b>Pratical Marks</b></div></td>
<td width="10%"><div align="center"><b>Total Marks</b></div></td>
<td width="10%"><div align="center"><b>Remarks</b></div></td>
</tr>
<tr>
#/etc/init/change_this_to_your_app_name.conf
description "App Name"
author "Admin Name <admin@app.com>"
start on virtual-filesystems
stop on runlevel [06]
env PATH=/usr/local/rbenv/shims:/usr/local/rbenv/bin:/usr/local/bin:/usr/bin:/bin
env RAILS_ENV=staging # what environment
#!/bin/bash
# Script to install a ubuntu trusty tahr 14.04 LTS template on xcp or
# Citrix (TM) Xenserver 5.6 and above.
# Copyright (C) 2014 Arne-Kristian Hingst - All Rights Reserved
# Permission to copy and modify is granted under the eupl license
# http://ec.europa.eu/idabc/servlets/Docbb6d.pdf?id=31979
# Last revised 04/20/2014
#
# Add your favourite mirror here
#!/bin/bash
# storetime: 1:30m 2:1h 3:3h 4:6h 5:12h 6:1d 7:3d 8:7d 9:forever
# addprivacy: no:no 1:basic 2:strong 3:shorten
picpaste () {
opts=( -F storetime=1 -F addprivacy=1 -F rules=yes )
link=http://www.picpaste.com/upload.php
curl -sA firefox "${opts[@]}" -F upload=@"$1" "$link" \
| sed -n '/Picture URL/{n;s/.*">//;s/<.*//p}'
# Bash function gen_random_filename
# Description: Generates random two-word names with date appended
# Requires a dictionary file, easily generated with `aspell dump master > dictionary.txt`
# or grab it from https://gist.githubusercontent.com/ttscoff/55493fe89c35ec1588ba/raw/
# Requires shuf and aspell
#
# Example results:
# reissue_degraded-2015-03-12@0254
# Cascades_derivatives-2015-03-12@0255
# oxygens_soaked-2015-03-12@0256
@thapakazi
thapakazi / react-native-talk.md
Last active August 29, 2015 14:25 — forked from peterjmag/react-native-talk.md
Let's build a React Native app in 20 minutes - React Berlin #1
# unicorn_rails -c /data/github/current/config/unicorn.rb -E production -D
rails_env = ENV['RAILS_ENV'] || 'production'
# 16 workers and 1 master
worker_processes (rails_env == 'production' ? 16 : 4)
# Load rails+github.git into the master before forking workers
# for super-fast worker spawn times
preload_app true
@thapakazi
thapakazi / maya
Created June 26, 2013 15:22 — forked from rhoit/maya
# असारको माया
यो माया भन्‍ने चिज कस्तो
गर्मीमा घाम नलागेको जस्तो
लोडसेडीगमा tube-lite बाल्या जस्तो॥
यतिमात्र होईन, कि कसो,
गाईको दुध पनि कस्तो सस्तो
ncell को sim-card लिए जस्तो
#!/usr/bin/env ruby
require 'csv'
# This assumes:
# - Ruby 1.9's CSV library, if you are using 1.8, use FasterCSV.
#
# https://raw.github.com/hadley/data-baby-names/master/baby-names.csv
csv_fname = "baby-names.csv"