Skip to content

Instantly share code, notes, and snippets.

@emschwartz
emschwartz / README.md
Last active June 14, 2026 21:43
The Most Popular Blogs of Hacker News in 2025

This is an OPML version of the HN Popularity Contest results for 2025, for importing into RSS feed readers.

Plug: if you want to find content related to your interests from thousands of obscure blogs and noisy sources like HN Newest, check out Scour. It's a free, personalized content feed I work on where you define your interests in your own words and it ranks content based on how closely related it is to those topics.

@spencerwooo
spencerwooo / termiWidget.js
Last active September 18, 2025 05:20
🍋 TermiWidget - Terminal-like Widget for iOS 14, made with Scriptable.
// Variables used by Scriptable.
// These must be at the very top of the file. Do not edit.
// icon-color: orange; icon-glyph: quote-right;
// Change these to your usernames!
const user = "spencer"
const jike = "4DDA0425-FB41-4188-89E4-952CA15E3C5E"
const telegram = "realSpencerWoo"
const github = "spencerwooo"
@louis-e
louis-e / UDPSocket.cs
Last active August 27, 2025 22:24 — forked from darkguy2008/UDPSocket.cs
Simple C# UDP server/client in 62 lines
using System;
using System.Net;
using System.Net.Sockets;
using System.Text;
namespace UDP
{
public class UDPSocket
{
public Socket _socket;
@y0ngb1n
y0ngb1n / docker-registry-mirrors.md
Last active June 12, 2026 12:51
国内的 Docker Hub 镜像加速器,由国内教育机构与各大云服务商提供的镜像加速服务 | Dockerized 实践 https://github.com/y0ngb1n/dockerized
@krisanalfa
krisanalfa / ultimate.md
Created October 16, 2015 08:25
Slim + Eloquent + Oracle

Your composer.json file:

{
    "require": {
        "slim/slim": "^2.6",
        "illuminate/database": "^5.1",
        "symfony/var-dumper": "^2.7",
        "yajra/laravel-oci8": "^2.4"
    }
@GavinFoo
GavinFoo / openvpn
Last active July 28, 2017 03:08
OpenVPN
======= 参考教程 =======
http://docs.ucloud.cn/software/vpn/OpenVPN4CentOS.html
http://nmshuishui.blog.51cto.com/1850554/1544212
http://www.cnblogs.com/electron/p/3488033.html
http://www.vpndp.com/ios-openvpn-settings-tutorial/ iPhone
1、安装openvpn
首先安装依赖库
@drmalex07
drmalex07 / getopt-example.sh
Last active May 3, 2025 11:08
A small example on Bash getopts. #bash #getopt #getopts
#!/bin/bash
#
# Example using getopt (vs builtin getopts) that can also handle long options.
# Another clean example can be found at:
# http://www.bahmanm.com/blogs/command-line-options-how-to-parse-in-bash-using-getopt
#
aflag=n
bflag=n
@runswithd6s
runswithd6s / getopt-boilerplate.sh
Last active October 24, 2021 07:28
BASH Script Boilerplate
#!/usr/bin/env bash
################################################################################
# Boilerplate Shell Script with getopt parsing
#
# This script is released to the Public Domain by Chad Walstrom
# Chad Walstrom <chewie@wookimus.net>.
################################################################################
NOACT=0
NAME=$(basename $0|sed 's/\(\..*\)$//')
VERSION="0.1"
@fethica
fethica / detect_language.php
Created December 13, 2013 20:24
Detect Browser Language in PHP
<?php
$lang = substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0, 2);
switch ($lang){
case "fr":
//echo "PAGE FR";
include("index_fr.php");//include check session FR
break;
case "it":
//echo "PAGE IT";
include("index_it.php");
@LucaRosaldi
LucaRosaldi / get-browser-language-code.php
Last active February 24, 2022 10:13
PHP: Get Browser Language, optionally passing a list of available languages.
<?php
/**
* Get browser language, optionally passing a list of available languages.
*
* @param [array] $available_languages Available languages for the site
* @param [string] $default Default language for the site
* @return [string] Language code
*/
function get_browser_language_code( $available_languages = [], $default = 'en' ) : string
{