Skip to content

Instantly share code, notes, and snippets.

@rougier
rougier / nano-org-wip.el
Created April 27, 2024 13:45
GNU Emacs / N Λ N O org mode
;;; nano-org-wip.el --- N Λ N O org mode -*- lexical-binding: t -*-
;; Copyright (C) 2024 Nicolas P. Rougier
;; Maintainer: Nicolas P. Rougier <Nicolas.Rougier@inria.fr>
;; This file is not part of GNU Emacs.
;; This file is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation; either version 3, or (at your option)
@ilnuribat
ilnuribat / DatePicker.qml
Last active May 6, 2024 16:05
Pure QML DatePicker, like android material design datePicker. QtQuick 2.7, QtQuick.Controls 2.0, Qt.labs.calendar 1.0. PS: dimensions in millimeters, so no depends on screen pixel density.
import QtQuick 2.7
import QtQuick.Window 2.2
import QtQuick.Controls 2.0
import Qt.labs.calendar 1.0
Rectangle {
id: mainForm
height: cellSize * 12
width: cellSize * 8
property double mm: Screen.pixelDensity
@aamiaa
aamiaa / CompleteDiscordQuest.md
Last active May 6, 2024 16:03
Complete Recent Discord Quest

Complete Recent Discord Quest

Note

This no longer works in browser!

Note

This no longer works if you're alone in vc! Somebody else has to join you!

How to use this script:

  1. Accept the quest under User Settings -> Gift Inventory
# WSL通过Win访问网络,所以WSL的网关指向的是Windows,DNS服务器指向的也是Windows,设置WSL的proxy为win的代理ip+端口即可
# WSL中的DNS server在/etc/resolv.conf中查看,该文件是由/etc/wsl.conf自动生成的。
# 如果关闭了wsl.conf中自动生成resolve.conf并自行修改了resolve.conf,DNS nameserver并不是本机win ip
# 需要开启wsl.conf的自动生成,再运行以下命令
# https://zhuanlan.zhihu.com/p/153124468
# ============WSL shell env settings================
# 添加到环境变量设置中,例如~/.bashrc
```
export hostip=$(cat /etc/resolv.conf |grep -oP '(?<=nameserver\ ).*')
var mediaJSON = { "categories" : [ { "name" : "Movies",
"videos" : [
{ "description" : "Big Buck Bunny tells the story of a giant rabbit with a heart bigger than himself. When one sunny day three rodents rudely harass him, something snaps... and the rabbit ain't no bunny anymore! In the typical cartoon tradition he prepares the nasty rodents a comical revenge.\n\nLicensed under the Creative Commons Attribution license\nhttp://www.bigbuckbunny.org",
"sources" : [ "http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4" ],
"subtitle" : "By Blender Foundation",
"thumb" : "images/BigBuckBunny.jpg",
"title" : "Big Buck Bunny"
},
{ "description" : "The first Blender Open Movie from 2006",
"sources" : [ "http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/ElephantsDream.mp4" ],
@Kaliloo
Kaliloo / sources.list
Created May 6, 2024 15:37 — forked from ph4ge/sources.list
Ubuntu 21.10 Impish Indri - apt sources.list
#deb cdrom:[Ubuntu 21.10 _Impish Indri_ - Release amd64 (20211012)]/ impish main restricted
# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
# newer versions of the distribution.
deb http://old-releases.ubuntu.com/ubuntu/ impish main restricted
# deb-src http://us.archive.ubuntu.com/ubuntu/ impish main restricted
## Major bug fix updates produced after the final release of the
## distribution.
deb http://old-releases.ubuntu.com/ubuntu/ impish-updates main restricted
@kb10uy
kb10uy / sus-specification-2.7.md
Last active May 6, 2024 15:59
SUS フォーマット v2.7 仕様

SUS Format Specification v2.7 (rev2)

注: SUS は今や Sliding Universal Score の略であり、 SeaUrchin Score ではありません。

1. 概要

  • テキストデータであり、全て printable character で構成される。
  • 拡張子: *.sus
  • EOL: CRLF もしくは LF
  • エンコード: 常に UTF-8
  • # で始まる行がデータとして意味を持ち、それ以外の行はコメントとして無視される。
  • 文字列データを指定する部分は " ~ " でクォートする。
@reecelucas
reecelucas / useScrollBlock.js
Last active May 6, 2024 15:57
React hook to enable/disable page scroll
import { useRef } from 'react';
const safeDocument = typeof document !== 'undefined' ? document : {};
/**
* Usage:
* const [blockScroll, allowScroll] = useScrollBlock();
*/
export default () => {
const scrollBlocked = useRef();
@samuel-ma
samuel-ma / constants
Created August 13, 2022 12:31 — forked from adrianhajdin/constants
project_hoobank
import { people01, people02, people03, facebook, instagram, linkedin, twitter, airbnb, binance, coinbase, dropbox, send, shield, star } from "../assets";
export const navLinks = [
{
id: "home",
title: "Home",
},
{
id: "features",
title: "Features",