Skip to content

Instantly share code, notes, and snippets.

@raven
raven / fetch-xcode.sh
Created September 23, 2022 12:24
Download Xcode without Apple ID
# Fetch ADCDownloadAuth cookie
curl --cookie-jar cookie_file 'https://developerservices2.apple.com/services/download?path=%2FDeveloper_Tools%2FXcode_14%2FXcode_14.xip'
# Download Xcode using fetched ADCDownloadAuth cookie
curl --cookie cookie_file --remote-name 'https://download.developer.apple.com/Developer_Tools/Xcode_14/Xcode_14.xip'
@Matthias247
Matthias247 / async_await_cancellation.md
Created May 28, 2019 06:09
Async/Await - The challenges besides syntax - Cancellation

Async/Await - The challenges besides syntax - Cancellation

This is the second article in a series of articles around Rusts new async/await feature. The first article about interfaces can be found here.

In this part of the series we want to a look at a mechanism which behaves very different in Rust than in all other languages which feature async/await support. This mechanism is Cancellation.

@csherratt
csherratt / ui.md
Last active August 15, 2024 15:17
Flora's Rust UI ramblings

Rust UI Difficulties

I wanted to give a little bit of a discussion on all my thinking about why UI's are a tricky to get right in Rust. I want to try and differentiate this discussion because there are a number of decent UI frameworks that have been bound to Rust. This is great! I do not want to discourage any of their work, they are wonderful members of our community.

What this is about is how it would be possible to write a good UI framework

#! /bin/bash
set -euo pipefail
# This script will remove automatic association for all networks not listed in the whitelist
# passed as the first argument. Passwords will NOT be removed from the Keychain.
#
# Alternatively, you can untick "Remember networks" in Network Preferences > Wi-Fi > Advanced,
# but then you won't be able to auto-join networks even temporarily, and you might already
# have a long list to go through.
#
@defeo
defeo / sidh-explained.md
Last active February 9, 2025 09:08
Key exchange in supersingular space-time

Key exchange in supersingular space-time

I was asked to vulgarize SIDH. Here is a very poor attempt!

Alice and Bob are space travelers. They both own a spaceship capable of traveling the galaxy through supersingular space-time at incredible speeds. They want to discuss a top-secret space mission, but they are afraid that the evil Zkptrx will spy upon their

@infinity0
infinity0 / fuck-gnome.txt
Last active March 15, 2022 04:56
Fuck GNOME
Right about now, Free Software court is in full effect
Judge Whax presiding
In the case of Free Software vs. the GNOME Foundation;
prosecuting attorneys are: Satoshi, YYY, and ZZ-motherfucking-Z
Order, order, order
Satoshi, take the motherfucking stand
Do you swear to tell the truth, the whole truth
and nothing but the truth so help your nerd ass?
@purpleidea
purpleidea / rluks.sh
Created April 25, 2016 17:43
Mount your encrypted LUKS drives by uuid over SSH
#!/bin/bash
# rluks.sh: Mount your encrypted LUKS drives by uuid over SSH
# Copyright (C) 2016+ James Shubin, AGPLv3+
# Written by James Shubin <[email protected]>
# You probably want to modify the following globals to match your needs...
SERVER='server.example.com' # expected server for running script
HOSTNAME='myserver' # expected hostname for running locally
MEDIA='/media/' # mount/media directory, eg: /media/
declare -A MAP # create an associative array
@david415
david415 / gist:120f157f62d20b11e39f
Last active November 14, 2015 19:29
secret onion git http repo! fuck github. no masters. no sys admins. only the secret police know how cool i am.
virtualenv virtenv-txtorcon
. ./virtenv-txtorcon/bin/activate
pip install txtorcon
export project=myproject
export secret=`pwgen 64`
mkdir -p public_html/$secret
cp -a $project public_html/$secret
touch public_html/index.html
$ curl --insecure -H "Host: http://github.com " -v https://github.com .A520FF6C4690D131A96967BEDD740751FB33A230.exit/
* About to connect() to proxy 127.0.0.1 port 8118 (#0)
* Trying 127.0.0.1...
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0* connected
* Connected to 127.0.0.1 (127.0.0.1) port 8118 (#0)
* Establish HTTP proxy tunnel to github.com.A520FF6C4690D131A96967BEDD740751FB33A230.exit:443
> CONNECT github.com.A520FF6C4690D131A96967BEDD740751FB33A230.exit:443 HTTP/1.1
> User-Agent: curl/7.26.0
@JeroMiya
JeroMiya / Scala Activity
Created July 19, 2014 03:14
Android Studio Scala Gradle config
package com.example.jeremybell.myapplication
import android.app.Activity
import android.os.Bundle
import android.view.Menu
import android.view.MenuItem
class MyActivity extends Activity {
override def onCreate(savedInstanceState: Bundle): Unit = {
super.onCreate(savedInstanceState)