Skip to content

Instantly share code, notes, and snippets.

View kkoomen's full-sized avatar

Kim 金可明 kkoomen

  • /dev/null
View GitHub Profile
@cmckni3
cmckni3 / package-clis-using-gluegun-pkg.md
Last active January 30, 2024 22:22
Package TypeScript CLIs with zeit/pkg

TypeScript & zeit/pkg

zeit/pkg needs to know which assets to include for TypeScript (tsconfig.json) and be able to resolve any dynamic requires.

This package.json shows how to configure zeit/pkg with gluegun.

In this example, the assets key is used for pkg to copy necessary files into the built binary and resolve the dynamic requires to find extensions and commands. TypeScript requires some basic type definitions (*.d.ts files) to compile and run which are included with the TypeScript compiler.

@sirbrillig
sirbrillig / phpcs.xml
Last active September 26, 2024 06:22 — forked from Ovsyanka/ruleset.xml
PHPCS rules for PSR2 with tabs, same-line braces, and missing variable detection
<?xml version="1.0"?>
<ruleset name="PaytonsStandard">
<description>
Originally from https://gist.github.com/Ovsyanka/e2ab2ff76e7c0d7e75a1e4213a03ff95
PSR2 with changes:
- tabs instead of spaces (https://gist.github.com/gsherwood/9d22f634c57f990a7c64)
- bracers on end of line instead new line
- unused/undefined variable detection (https://github.com/sirbrillig/phpcs-variable-analysis)
</description>
<arg name="tab-width" value="4"/>
@algb12
algb12 / UDPGeolocate.sh
Last active June 7, 2021 19:34
Geolocates strangers on Omegle, Chatroulette and similar sites. Tested on OS X 10.10.5 and Ubuntu 16.04.
#!/bin/bash
# Real-time UDP IP Geolocator
printf "### REAL-TIME UDP IP GEOLOCATOR ###\n"
printf "===================================\n"
# Query user options
read -p "Please enter the interface on which to listen for connections (Default: Detection by script): " interface
read -p "Please enter the minimum packet size which should trigger a frame recording (Default: 200): " minPackLen
read -p "Please enter the UDP port number on which to listen for connections (Default: Detection by script (follow instructions later on in config!)): " port
@joshbuchea
joshbuchea / semantic-commit-messages.md
Last active November 15, 2024 23:29
Semantic Commit Messages

Semantic Commit Messages

See how a minor change to your commit message style can make you a better programmer.

Format: <type>(<scope>): <subject>

<scope> is optional

Example

@bmhatfield
bmhatfield / .profile
Last active November 14, 2024 12:11
Automatic Git commit signing with GPG on OSX
# In order for gpg to find gpg-agent, gpg-agent must be running, and there must be an env
# variable pointing GPG to the gpg-agent socket. This little script, which must be sourced
# in your shell's init script (ie, .bash_profile, .zshrc, whatever), will either start
# gpg-agent or set up the GPG_AGENT_INFO variable if it's already running.
# Add the following to your shell init to set up gpg-agent automatically for every shell
if [ -f ~/.gnupg/.gpg-agent-info ] && [ -n "$(pgrep gpg-agent)" ]; then
source ~/.gnupg/.gpg-agent-info
export GPG_AGENT_INFO
else
DB::listen(
function ($sql) {
// $sql is an object with the properties:
// sql: The query
// bindings: the sql query variables
// time: The execution time for the query
// connectionName: The name of the connection
// To save the executed queries to file:
// Process the sql and the bindings:
@rxaviers
rxaviers / gist:7360908
Last active November 15, 2024 16:55
Complete list of github markdown emoji markup

People

:bowtie: :bowtie: 😄 :smile: 😆 :laughing:
😊 :blush: 😃 :smiley: ☺️ :relaxed:
😏 :smirk: 😍 :heart_eyes: 😘 :kissing_heart:
😚 :kissing_closed_eyes: 😳 :flushed: 😌 :relieved:
😆 :satisfied: 😁 :grin: 😉 :wink:
😜 :stuck_out_tongue_winking_eye: 😝 :stuck_out_tongue_closed_eyes: 😀 :grinning:
😗 :kissing: 😙 :kissing_smiling_eyes: 😛 :stuck_out_tongue: