Skip to content

Instantly share code, notes, and snippets.

View SARDONYX-sard's full-sized avatar
🌴
On vacation

SARDONYX SARDONYX-sard

🌴
On vacation
View GitHub Profile
@tracend
tracend / gist:912308
Created April 10, 2011 12:40
DirectInput keyboard scan codes
/****************************************************************************
*
* DirectInput keyboard scan codes
*
****************************************************************************/
#define DIK_ESCAPE 0x01
#define DIK_1 0x02
#define DIK_2 0x03
#define DIK_3 0x04
#define DIK_4 0x05
@t-mat
t-mat / keyrate.cmd
Last active October 16, 2023 08:21
Windows: keyrate - keyboard repeat rate configuration utility.
@setlocal enabledelayedexpansion & set "ARGS=%*" & powershell -nop -ex Bypass -c "Add-Type (gc '%~dpf0'|select -Skip 1|Out-String); exit [Program]::Main();" & exit /b !ERRORLEVEL!
// How can I increase the key repeat rate beyond the OS's limit?
// https://stackoverflow.com/a/11056655
using System;
using System.Linq;
using System.Runtime.InteropServices;
public static class Program {

http://www.wtfpl.net/faq/ の翻訳(非公式)です。 以下の文章には何も保証がありません。

どのように WTFPLを使いますか?

ステップ1. WTFPLの全文をコピー&ペーストもしくはダウンロードし、あなたの成果物と共に配布します。一般的にライセンスファイルの名前は COPYING です。成果物が複数のライセンスを採用している場合は、COPYING.WTFPL というファイル名が一般的です。

ステップ2. あなたの著作権文章に次の文言を追加してください。

@uupaa
uupaa / get.path.for.node.js.md
Last active December 5, 2023 11:18
node.js で絶対パスや相対パスを取得する方法 npm __dirname

node.js でパスを取得する方法についてのメモ

$ node ~/hoge/Foo.js/a.js

を実行したときに、

  • process.argv[1] から、node コマンドに指定された a.js のパス( ~/hoge/Foo.js/a.js )を取得できます
@lukas-h
lukas-h / license-badges.md
Last active July 11, 2024 07:00
Markdown License Badges for your Project

Markdown License badges

Collection of License badges for your Project's README file.
This list includes the most common open source and open data licenses.
Easily copy and paste the code under the badges into your Markdown files.

Notes

  • The badges do not fully replace the license informations for your projects, they are only emblems for the README, that the user can see the License at first glance.

Translations: (No guarantee that the translations are up-to-date)

@HaleTom
HaleTom / print256colours.sh
Last active June 29, 2024 16:16
Print a 256-colour test pattern in the terminal
#!/bin/bash
# Tom Hale, 2016. MIT Licence.
# Print out 256 colours, with each number printed in its corresponding colour
# See http://askubuntu.com/questions/821157/print-a-256-color-test-pattern-in-the-terminal/821163#821163
set -eu # Fail on errors or undeclared variables
printable_colours=256
@JBlond
JBlond / bash-colors.md
Last active July 18, 2024 08:06 — forked from iamnewton/bash-colors.md
The entire table of ANSI color codes.

Regular Colors

Value Color
\e[0;30m Black
\e[0;31m Red
\e[0;32m Green
\e[0;33m Yellow
\e[0;34m Blue
\e[0;35m Purple
@razorness
razorness / gaugeJS-index.d.ts
Last active January 23, 2022 06:32
gauge.js / gaugeJS Typescript definition
// Type definitions for gauge.js (gaugeJS)
// Project: https://github.com/razorness/gauge.js (forked from https://github.com/bernii/gauge.js)
// Definitions by: Volker Nauruhn <https://github.com/razorness>
// TypeScript Version: 2.1
declare module 'gaugeJS' {
interface BaseOptions {
/**