Skip to content

Instantly share code, notes, and snippets.

View leo424y's full-sized avatar

Fly Chang leo424y

View GitHub Profile
@caasi
caasi / maple_future_0.txt
Created February 17, 2014 08:59
十五年前,前輩先進們討論著 BBS 的未來。
作者 Thor (淡出) 看板 plan
標題 Maple未來發展
時間 Fri Jul 24 09:47:41 1998
───────────────────────────────────────
只是隨便取個聳動的標題而已:ppp
現在 bbtpd.c opus還沒寫完就消失了,
我在想直接接下去寫會不會對他大不敬呀?:P
@vedant
vedant / gist:9333992
Last active September 26, 2024 01:23
Export note files from Google Keep
/* Vedant Misra (vedantmisra.com) (github.com/vedant)
*
* Script for exporting Google Keep note files.
*
* This does not handle attachments or checklists, only note files. Downloads
* each note to a .txt file named for the note's title.
*
* To use this, go to https://drive.google.com/keep/ and wait for the page to
* fully load all of your saved notes; scroll to the bottom to confirm they're
* loaded. Then paste the below in your URI bar, go to the start of the line,
@DanHerbert
DanHerbert / fix-homebrew-npm.md
Last active June 8, 2025 15:03
Instructions on how to fix npm if you've installed Node through Homebrew on Mac OS X or Linuxbrew

OBSOLETE

This entire guide is based on an old version of Homebrew/Node and no longer applies. It was only ever intended to fix a specific error message which has since been fixed. I've kept it here for historical purposes, but it should no longer be used. Homebrew maintainers have fixed things and the options mentioned don't exist and won't work.

I still believe it is better to manually install npm separately since having a generic package manager maintain another package manager is a bad idea, but the instructions below don't explain how to do that.

Fixing npm On Mac OS X for Homebrew Users

Installing node through Homebrew can cause problems with npm for globally installed packages. To fix it quickly, use the solution below. An explanation is also included at the end of this document.

# Additional translations at https://github.com/plataformatec/devise/wiki/I18n
zh-TW:
devise:
confirmations:
confirmed: "您的帳號已通過驗證,現在您已成功登入。"
send_instructions: "您將在幾分鐘後收到一封電子郵件,內有驗證帳號的步驟說明。"
send_paranoid_instructions: "如果我們有您的信箱,您將會收到一封驗證您的帳號的電子郵件。"
failure:
already_authenticated: "您已經登入。"
@natelandau
natelandau / .bash_profile
Last active October 27, 2025 14:01
Mac OSX Bash Profile
# ---------------------------------------------------------------------------
#
# Description: This file holds all my BASH configurations and aliases
#
# Sections:
# 1. Environment Configuration
# 2. Make Terminal Better (remapping defaults and adding functionality)
# 3. File and Folder Management
# 4. Searching
# 5. Process Management
@tsiege
tsiege / The Technical Interview Cheat Sheet.md
Last active October 13, 2025 20:38
This is my technical interview cheat sheet. Feel free to fork it or do whatever you want with it. PLEASE let me know if there are any errors or if anything crucial is missing. I will add more links soon.

ANNOUNCEMENT

I have moved this over to the Tech Interview Cheat Sheet Repo and has been expanded and even has code challenges you can run and practice against!






\

@xdite
xdite / workshop.md
Last active August 29, 2015 14:00
Ruby on Rails Outreach Worshop

場地條件

  1. 場地要有 50 M 對外頻寬。
  2. 場地要有強壯的 wifi, 可以讓 20-30 人同時抓東西不是問題。(需要 gem install)
  3. 方便到達(最好在市中心或其他容易到的地方)
  4. 場地要能提供至少 20-30 人的電源插座
  5. 場地要能提供供 20-30 人用的桌椅 (大桌約 6-8 張)
  6. 場地要能提供投影機以及布幕設備
  7. 場地要能提供飲料和零食。(或者不介意學員自己帶去)
@xdite
xdite / 遠端佈署最佳實踐.md
Last active March 11, 2020 10:23
遠端佈署最佳實踐

遠端佈署最佳實踐

本文由 xdite 授權提供,為 Rails 101 第七章部分內容

第一部分

佈署 Rails Production 所需要的環境

佈署 Rails Application 是件說簡單很簡單,說複雜也很複雜的事。佈署的手法有很多種搭配,筆者最推薦的其實是在 Ubuntu / Debian 安裝 Ruby Enterprise Edition,web sever 使用 nginx + mod_rails 的組合。之後再撰寫 Capistrano 的 recipe 來 deploy。

@DanielMuller
DanielMuller / ebs_autoscale.sh
Last active October 17, 2024 03:33
Allow autoscaling EBS volumes based on disk usage
#!/bin/bash
# Allows to attach and remove EBS volumes managed under LVM to
# have a dynamically sized partition attached to an EC2 instance
#
# Intance needs either to be launched with a role able to access to relevant AWS API endpoints
# or the credentials can be hardcoded in the config.
#
# Minimal IAM Role:
# {
/**
* Retrieves all the rows in the active spreadsheet that contain data and logs the
* values for each row.
* For more information on using the Spreadsheet API, see
* https://developers.google.com/apps-script/service_spreadsheet
*/
function readRows() {
var sheet = SpreadsheetApp.getActiveSheet();
var rows = sheet.getDataRange();
var numRows = rows.getNumRows();