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
Normally macOS can't associate and run a specified shell script when you doubleclick on a file, but the macOS Automator can make it work. | |
Here's the steps: | |
* Run the Automator app and choose "Create new" | |
* Drag “Run Shell Script” into grey area | |
![apptype in automator](https://mengstr.github.io/gist-images/Digital/automator-app-type.png) |
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
Info 810d0101 820d0402091200 | |
? 810c020901 820c0101 | |
Info 810d0102 820d050900300500 | |
Protect 81060802f7ffffffffffff 82060102 | |
Reset 810b0101 820b0101 | |
Info 810d01ff 820d01ff | |
Info 810d0101 820d0402091200 | |
? 810c020901 820c0101 | |
Info 810d0102 820d050900300500 | |
Protect 81060104 82060100 |
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
225.261250 SYNC SETUP | |
225.271958 Address=0x00 Endpoint=0x00 | |
225.286000 SYNC DATA0 | |
225.296667 bmRequestType=0x80 Data direction=Device to host, Type=Standard, Recipient=Device | |
225.302042 bRequest=0x06 GET_DESCRIPTOR | |
225.307375 wValue=0x0100 Descriptor=DEVICE, Index=0x00 | |
225.318000 wIndex=0x0000 | |
225.328708 wLength=0x0040 |
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
431017708 SETUP | |
Address=0x00 Endpoint=0x00 | |
431042417 DATA0 | |
bmRequestType=0x00 Data direction=No data, Type=Standard, Recipient=Device | |
bRequest=0x05 SET_ADDRESS | |
wValue=0x0008 Address=0x08 | |
wIndex=0x0000 | |
wLength=0x0000 |
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
// "github.com/fsnotify/fsnotify" | |
watcher, err := fsnotify.NewWatcher() | |
defer watcher.Close() | |
go func() { | |
for { | |
select { | |
case event, _ := <-watcher.Events: | |
fmt.Printf("PID %d, Event %v\n", os.Getpid(), event) | |
if event.Op&fsnotify.Create == fsnotify.Create || event.Op&fsnotify.Write == fsnotify.Write { |
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
# | |
# Setup of LAMP on virgin Azure Ubuntu 18.04 | |
# Run this as root | |
# | |
# Version 2021-03-15a | |
# | |
SITE=$1 | |
EMAIL=$2 | |
if [[ -z "$SITE" ]] || [[ -z "$EMAIL" ]]; then |
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
# | |
# for c in {16000..275000..1}; do f=$(awk "BEGIN {print $c/1000}"); o=$(icepll -i 100 -o $f | grep achieved | tr -c -d 0-9\.); echo $f is $o; done > plltable.txt | |
# cat plltable.txt | uniq -f 1 | pbcopy | |
# | |
16 is 16.016 | |
16.044 is 16.071 | |
16.083 is 16.094 | |
16.12 is 16.146 | |
16.179 is 16.211 |
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
; | |
; Results for sorting 8 bytes | |
; | |
; First value is the number of scanlines required for pre-sorted data, second is | |
; for data that is fully reverse order. | |
; | |
; Yellow 3.0 - 7.5 (369 bytes) Continous Unrolled | |
; Orange 7.5 - 12.0 (262 bytes) Continous Subroutined | |
; Red 4.0 - 9.0 (138 bytes) Continous Fallthrough | |
; Blue 2.4 - 29.9 ( 51 bytes) Bubblesort |
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
curl "https://circleci.com/gh/SmallRoomLabs/circleci-demo-go/tree/master.svg?style=shield&circle-token=632f67b7a9980f59c8b802d6a155885b55313a70" | |
<?xml version="1.0" encoding="UTF-8"?> | |
<svg xmlns="http://www.w3.org/2000/svg" width="93" height="20"> | |
<linearGradient id="b" x2="0" y2="100%"> | |
<stop offset="0" stop-color="#bbb" stop-opacity=".1" /> | |
<stop offset="1" stop-opacity=".1" /> | |
</linearGradient> | |
<mask id="a"> | |
<rect width="93" height="20" rx="3" fill="#fff" /> |
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
// | |
// Blink the blue led using direct port manipulation on ESP8266 | |
// The blue led on a NoceMCU is D4 for Arduino / GPIO2 on hardware level | |
// | |
// Measuring the speed when running at 80Mhz and not counting the Loop() or while() overhead | |
// I get a significant speed increase - over an order of magnitude! | |
// | |
// DigitaWrite()'s results in a 479KHz squarewave | |
// GPOS/GPOS's results in a 5.72MHz squarewave | |
// |
NewerOlder