This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// updated code for https://github.com/unbeschwert/3-2-1 | |
use std::{fs, io::Write}; | |
use anyhow::{Result, Context}; | |
use dirs::home_dir; | |
use scraper::{Element, Html, Selector}; | |
static URL: &str = "https://jamesclear.com/3-2-1"; | |
const QUESTION_HEADLINE: &str = "1 QUESTION FOR YOU"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// RUSTFLAGS="-C panic=abort" cargo build --release --target x86_64-unknown-none && ./target/x86_64-unknown-none/debug/hello-world; echo $? | |
#![no_std] | |
#![no_main] | |
use core::arch::asm; | |
use core::slice; | |
pub const STDOUT_FILENO: u32 = 1; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env php | |
<?php | |
require __DIR__ . '/vendor/autoload.php'; | |
use Aws\S3\S3Client; | |
$s3 = new S3Client([ | |
'version' => 'latest', | |
'endpoint' => 'https://s3.eu-central-1.amazonaws.com', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
set -ex | |
## this needs to be run once for ./mkimage.sh to work | |
# doas cp -v /usr/share/apk/keys/armhf/* /etc/apk/keys/ | |
mkdir -p ~/out | |
rm -vf ~/out/*/* ~/out/diff.html | |
for x in 1 2; do |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Cargo.toml: geo = "0.12.2" | |
use geo::*; | |
use geo::prelude::*; | |
fn main() { | |
let polygon = Polygon::new(LineString::from(vec![ | |
Point::new(9.764785766601562, 53.63975308945899), | |
Point::new(9.827270507812, 53.59494998253459), | |
Point::new(9.9151611328125, 53.663153974456456), |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- a/ct-sub-domains.lua | |
+++ b/ct-sub-domains.lua | |
@@ -6,10 +6,17 @@ | |
function run(domain) | |
session = http_mksession() | |
- request = http_request(session, 'GET', 'https://api.certspotter.com/v1/issuances?include_subdomains=true&expand=dns_names&expand=issuer&expand=cert&domain=' .. domain['value'], { | |
+ request = http_request(session, 'GET', 'https://api.certspotter.com/v1/issuances', { | |
+ query={ | |
+ include_subdomains='true', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Maintainer: Philipp A <flying-sheep@web.de> | |
# Contributor: kpcyrd <git@rxv.cc> | |
pkgname=diesel_cli | |
pkgver=1.4.0 | |
pkgrel=1 | |
pkgdesc='CLI for the Diesel crate' | |
arch=('i686' 'x86_64') | |
url="http://diesel.rs/" | |
license=('MIT' 'Apache') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- # steps to reproduce | |
-- rm -f foo.db; sqlite3 foo.db < up.sql; echo '.schema' | sqlite3 foo.db | |
-- | |
-- debian stable (works as expected): | |
-- 3.16.2 2017-01-06 16:32:41 a65a62893ca8319e89e48b8a38cf8a59c69a8209 | |
-- | |
-- archlinux (corrupted database): | |
-- 3.26.0 2018-12-01 12:34:55 bf8c1b2b7a5960c282e543b9c293686dccff272512d08865f4600fb58238b4f9 | |
CREATE TABLE foo ( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in | |
index 2ac1bbca..3fbfc5a7 100644 | |
--- a/scripts/makepkg.sh.in | |
+++ b/scripts/makepkg.sh.in | |
@@ -55,6 +55,7 @@ splitpkg_overrides=('pkgdesc' 'arch' 'url' 'license' 'groups' 'depends' | |
readonly -a build_options splitpkg_overrides | |
known_hash_algos=('md5' 'sha1' 'sha224' 'sha256' 'sha384' 'sha512' 'whirlpool') | |
+secure_hash_algos=('sha224' 'sha256' 'sha384' 'sha512' 'whirlpool') | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import subprocess | |
import time | |
import sys | |
SCANCODES = { | |
'ESC': [[0x01], [0x81]], | |
'1': [[0x02], [0x82]], '!': [[0x2A, 0x02], [0x82, 0xAA]], | |
'2': [[0x03], [0x83]], '@': [[0x2A, 0x03], [0x83, 0xAA]], |
NewerOlder