Skip to content

Instantly share code, notes, and snippets.

View zetavg's full-sized avatar

Pokai Chang zetavg

View GitHub Profile
@axemclion
axemclion / index.android.js
Last active January 20, 2016 06:18
Cordova Plugins in React native
'use strict';
var React = require('react-native');
var {
AppRegistry,
StyleSheet,
Text,
View,
NativeModules,
TouchableHighlight,
@Zenexer
Zenexer / Mac Keyboard Symbols.md
Last active December 7, 2024 17:57
List of Mac/Apple keyboard symbols
@zetavg
zetavg / set-app.sh
Last active August 29, 2015 14:15
`bin/rake` tasks and `bin/rails console` with ease on AWS OpsWorks Instances running Passenger Rails App Server.
# $ curl -L http://git.io/opsrp_setapp > set-app.sh
# $ . set-app.sh app_name
#
# cd into app directory and sets the environment variables
# on AWS OpsWorks Instances running Passenger Rails App Server.
APP_NAME=$1 && \
cd "/srv/www/${APP_NAME}/current" && \
export RAILS_ENV=production && \
\
anonymous
anonymous / gist:53d90be18a44f742496a
Created January 28, 2015 13:56
spider
import requests
import bs4
import csv
url = []
url.append('http://www.ntust.edu.tw/files/40-1000-167-')
url.append('.php')
data = []
tmp = 'title', 'date', 'content'
data.append(tmp)
@zetavg
zetavg / codeship_rails_opsworks_deploy.sh
Last active August 29, 2015 14:14
The script used to deploy Rails apps to AWS OpsWorks via Codeship.
#!/bin/sh
#
# The script used to deploy Rails apps to AWS OpsWorks via Codeship.
#
# It requires the following environment variables to be set:
#
# - AWS_ACCESS_KEY_ID
# - AWS_SECRET_ACCESS_KEY
# - APP_NAME
# - S3_BUCKET
@coodoo
coodoo / quick-guide-to-react-flux
Last active May 1, 2017 12:04
這是 jsdc 2014 演講後提供的快速學習指南。有問題請到 [React.tw 中文群組](https://www.facebook.com/groups/reactjs.tw/) 討論
# 內容
# repo 位置
- https://github.com/facebook/react
- https://github.com/facebook/flux
# 官網
- React
* http://facebook.github.io/react/
@max-mapper
max-mapper / catcafes.geojson
Last active February 27, 2017 14:28
cat cafes in taipei
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@zetavg
zetavg / smoothScrolling.coffee
Last active August 29, 2015 14:07
讓網頁中的 <a href="#foo">bar</a> 都平滑捲動。
$("a[href*=#]:not([href=#])").click ->
if location.pathname.replace(/^\//, "") is @pathname.replace(/^\//, "") and location.hostname is @hostname
target = $(@hash)
target = (if target.length then target else $("[name=#{@hash.slice(1)}]"))
if target.length
$("html, body").animate
scrollTop: target.offset().top - 18
, 1000
false
@zetavg
zetavg / Logon.md
Created September 28, 2014 20:24
logon.zsh-theme - a theme for ZSH with Powerline, Git, NVM, RVM status and responsive design

Logon

Yet another oh-my-zsh theme, based on [agnoster][1] - A Powerline-inspired theme for ZSH

Logon Responsive

README

@lucabrunox
lucabrunox / autotools.nix
Last active December 2, 2021 18:16
Nix pill 12
pkgs: attrs:
with pkgs;
let defaultAttrs = {
builder = "${bash}/bin/bash";
args = [ ./builder.sh ];
setup = ./setup.sh;
baseInputs = [ gnutar gzip gnumake gcc binutils coreutils gawk gnused gnugrep patchelf findutils ];
buildInputs = [];
system = builtins.currentSystem;
};