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 | |
# | |
# This script pretty-prints timing/utilization reports produced by nextpnr. | |
# You can use it in your build process like this: | |
# | |
# nextpnr-ecp5 ... --report report.json | |
# ./print-report.py < report.json | |
# | |
# License: CC0 <https://creativecommons.org/publicdomain/zero/1.0> |
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
# Adapted from https://github.com/bennofs/nix-index/blob/master/command-not-found.sh | |
command_not_found_handle () { | |
if [ -n "${MC_SID-}" ] || ! [ -t 1 ]; then | |
>&2 echo "$1: command not found" | |
return 127 | |
fi | |
echo -n "searching nix-index..." | |
ATTRS=$(@nix-locate@ --minimal --no-group --type x --type s --top-level --whole-name --at-root "/bin/$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
local state, data, reactor, turbine, info_window, rules_window | |
local STATES = { | |
READY = 1, -- Reactor is off and can be started with the lever | |
RUNNING = 2, -- Reactor is running and all rules are met | |
ESTOP = 3, -- Reactor is stopped due to rule(s) being violated | |
UNKNOWN = 4, -- Reactor or turbine peripherals are missing | |
} | |
------------------------------------------------ |
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
# This is a hacky workaround for the Discord desktop app tray icons being | |
# blurry. It adds a script to the top of the app's wrapper script that unpacks | |
# `core.asar` (the archive containing the icons), replaces the 24x24 icons with | |
# 128x128 ones from the Papirus icon theme, and repacks everything. The sha256 | |
# of the patched `core.asar` is saved in `core.asar.sha256` and checked when the | |
# script is run again to avoid repeated work. | |
# | |
# Comparison: https://i.imgur.com/SBGJlzX.png | |
# | |
# It should work with discord, discord-ptb, and discord-canary. |
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
# nix profile install -f cross-compiler.nix | |
let | |
pkgs = import <nixpkgs> { | |
crossSystem = { | |
config = "riscv32-none-elf"; | |
libc = "newlib"; | |
gcc.abi = "ilp32"; | |
gcc.arch = "rv32i"; | |
}; | |
}; |
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
{ pkgs ? import <nixpkgs> { } }: | |
let | |
patchedMono = pkgs.mono.overrideAttrs (old: { | |
patches = (old.patches or [ ]) ++ [ | |
(pkgs.fetchpatch { | |
url = "https://patch-diff.githubusercontent.com/raw/mono/mono/pull/21136.patch"; | |
sha256 = "sha256-4mUkkRl2IoNjkZN8+1Ps3kvI9Tu2BnH4YqeRZ6A/UMU="; | |
}) | |
]; |
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
local read_position | |
read_position = function() | |
local read_axis | |
read_axis = function(name, color) | |
term.setTextColor(color) | |
write(tostring(name) .. ": ") | |
term.setTextColor(colors.white) | |
return tonumber(read()) | |
end | |
print("Enter the position of this computer (NOT the position of the modem).") |
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 bash | |
REPOSITORY=InternetUnexplorer/kwin-lowlatency-overlay | |
set -eu | |
source .secrets | |
curl -X POST \ | |
-H "Accept: application/vnd.github.v3+json" \ |
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/driver/razerkbd_driver.c b/driver/razerkbd_driver.c | |
index 909a797..a209cfc 100644 | |
--- a/driver/razerkbd_driver.c | |
+++ b/driver/razerkbd_driver.c | |
@@ -1242,6 +1242,7 @@ static ssize_t razer_attr_write_mode_starlight(struct device *dev, struct device | |
} | |
break; | |
+ case USB_DEVICE_ID_RAZER_BLADE_STEALTH_MID_2017: | |
case USB_DEVICE_ID_RAZER_BLADE_STEALTH_LATE_2017: |
NewerOlder