Skip to content

Instantly share code, notes, and snippets.

View roycrxtw's full-sized avatar

Roy Cooper roycrxtw

  • ViewSonic
  • Taiwan
View GitHub Profile
@doggy8088
doggy8088 / Angular 18 Dev Setup.md
Last active May 24, 2024 16:20
Angular 18 開發環境說明

Angular 18 開發環境說明

為了能讓大家能夠順利的建立起 Angular 18 開發環境,以下是需要安裝的相關軟體與安裝步驟與說明。

Angular LOGO

[ 作業系統 ]

  • Windows 10 以上版本
  • Mac OS X 10.6 以上版本
@leafsummer
leafsummer / install_pstree
Created May 23, 2016 02:45
install pstree
Linux pstree shows running processes as a tree. The tree is rooted at either pid or init if pid is omitted. If a user name is specified, all process trees rooted at processes owned by that user are shown.
Install pstree
#On Mac OS
brew install pstree
#On Fedora/Red Hat/CentOS
yum install psmisc #using psmisc package for pstree
#On Ubuntu/Debian APT
@twolfson
twolfson / README.md
Last active August 1, 2023 10:45
Node.js job queue evaluation

We are building a Node.js service which will need asynchronous support for tasks like sending emails. Here's our evaluation:

@markerikson
markerikson / connectExample.js
Last active March 5, 2024 01:24
React-Redux connect example
import {action1, action2} from "myActions";
import {bindActionCreators} from "redux";
import {connect} from "react-redux";
const mapStateToProps = (state, ownProps) = {
return {
counter : state.counter,
someComponentValue : state.things[ownProps.someIdProp]
};
}
@subfuzion
subfuzion / curl.md
Last active June 20, 2024 13:48
curl POST examples

Common Options

-#, --progress-bar Make curl display a simple progress bar instead of the more informational standard meter.

-b, --cookie <name=data> Supply cookie with request. If no =, then specifies the cookie file to use (see -c).

-c, --cookie-jar <file name> File to save response cookies to.

@scari
scari / aws_latency.md
Last active November 25, 2020 04:02
AWS Latency

Disclaimer

This is not an official report nor reliable benchmark. The testing environments are vary. These EC2 latencies are measured by http://aws-latency.altaircp.com/ Thanks to my friends!

If you want to add a result from your location, feel free to comment on this gist. Please note that you need to try it several times to get an accurate result.

Seoul, Korea

Asia Pacific (Seoul)	ap-northeast-2	19ms
Asia Pacific (Tokyo)	ap-northeast-1	92ms
@denji
denji / http-benchmark.md
Last active June 20, 2024 14:22
HTTP(S) Benchmark Tools / Toolkit for testing/debugging HTTP(S) and restAPI (RESTful)
@flesch
flesch / basic-auth.js
Last active July 27, 2022 12:39
HTTP Basic Authentication with Express, without express.basicAuth.
var express = require("express");
var app = express();
app.get("/restricted", function(req, res, next){
// Grab the "Authorization" header.
var auth = req.get("authorization");
// On the first request, the "Authorization" header won't exist, so we'll set a Response
// header that prompts the browser to ask for a username and password.
@yorkxin
yorkxin / rfc6750.md
Created September 17, 2013 07:54
RFC 6750 in Markdown - Edited from http://tools.ietf.org/rfc/rfc6750.txt
Internet Engineering Task Force (IETF)                          M. Jones
Request for Comments: 6750                                     Microsoft
Category: Standards Track                                       D. Hardt
ISSN: 2070-1721                                              Independent
                                                            October 2012

The OAuth 2.0 Authorization Framework: Bearer Token Usage

Abstract

@webdesserts
webdesserts / Gulpfile.js
Last active April 3, 2023 08:16
Automatically reload your node.js app on file change with Gulp (https://github.com/wearefractal/gulp).
// NOTE: I previously suggested doing this through Grunt, but had plenty of problems with
// my set up. Grunt did some weird things with scope, and I ended up using nodemon. This
// setup is now using Gulp. It works exactly how I expect it to and is WAY more concise.
var gulp = require('gulp'),
spawn = require('child_process').spawn,
node;
/**
* $ gulp server
* description: launch the server. If there's a server already running, kill it.