Skip to content

Instantly share code, notes, and snippets.

View dacr's full-sized avatar
🕷️

Crosson David dacr

🕷️
View GitHub Profile
@dacr
dacr / catsparse-hello-1.sc
Created March 28, 2025 09:02
cats-parse graph query language experiment - hello world 1 / published by https://github.com/dacr/code-examples-manager #0d961a8d-0863-4c3f-92d5-793e6f86ff7a/57b00bd8f6d9d8667bebf43fe54091f3cdda8d7d
// summary : cats-parse graph query language experiment - hello world 1
// keywords : scala, typelevel, cats-parse, hello-world, @testable
// publish : gist
// authors : David Crosson
// license : Apache NON-AI License Version 2.0 (https://raw.githubusercontent.com/non-ai-licenses/non-ai-licenses/main/NON-AI-APACHE2)
// id : 0d961a8d-0863-4c3f-92d5-793e6f86ff7a
// created-on : 2025-03-13T14:02:18+01:00
// managed-by : https://github.com/dacr/code-examples-manager
// run-with : scala-cli $file
@dacr
dacr / closures.go
Created March 28, 2025 09:02
go closures / published by https://github.com/dacr/code-examples-manager #0fe71bda-9959-438c-adf7-4b53c50fea24/4519afe9647f8a6a7ee3ce70c2ee3c12ae353208
/*?sr/bin/true; exec /usr/bin/env nix-shell -p go --run "go run $0" #*/
// summary : go closures
// keywords : go, closures, @testable
// publish : gist
// authors : David Crosson
// license : Apache NON-AI License Version 2.0 (https://raw.githubusercontent.com/non-ai-licenses/non-ai-licenses/main/NON-AI-APACHE2)
// id : 0fe71bda-9959-438c-adf7-4b53c50fea24
// created-on : 2025-03-27T10:08:08+01:00
// managed-by : https://github.com/dacr/code-examples-manager
// run-with : nix-shell -p go --run "go run $file"
@dacr
dacr / generics.go
Created March 28, 2025 09:02
go generics / published by https://github.com/dacr/code-examples-manager #34fb816b-0528-47fe-91b5-0173ffa670a5/329135f1b6b086e920b59ac89cd1998a234afcf4
/*?sr/bin/true; exec /usr/bin/env nix-shell -p go --run "go run $0" #*/
// summary : go generics
// keywords : go, generics, @testable
// publish : gist
// authors : David Crosson
// license : Apache NON-AI License Version 2.0 (https://raw.githubusercontent.com/non-ai-licenses/non-ai-licenses/main/NON-AI-APACHE2)
// id : 34fb816b-0528-47fe-91b5-0173ffa670a5
// created-on : 2025-03-27T09:36:13+01:00
// managed-by : https://github.com/dacr/code-examples-manager
// run-with : nix-shell -p go --run "go run $file"
@dacr
dacr / concurrency-singleton.go
Created March 28, 2025 09:02
go routines singleton / published by https://github.com/dacr/code-examples-manager #bf57f6e8-ddad-427b-99bd-e5027c56e9db/a88dba1529163054bf2e0c4890f2de7a207e1246
/*?sr/bin/true; exec /usr/bin/env nix-shell -p go --run "go run $0" #*/
// summary : go routines singleton
// keywords : go, goroutines, singleton, @testable
// publish : gist
// authors : David Crosson
// license : Apache NON-AI License Version 2.0 (https://raw.githubusercontent.com/non-ai-licenses/non-ai-licenses/main/NON-AI-APACHE2)
// id : bf57f6e8-ddad-427b-99bd-e5027c56e9db
// created-on : 2025-03-27T14:28:34+01:00
// managed-by : https://github.com/dacr/code-examples-manager
// run-with : nix-shell -p go --run "go run $file"
@dacr
dacr / defer-trap.go
Created March 28, 2025 09:02
go defer trap / published by https://github.com/dacr/code-examples-manager #613fc74b-18b9-4df3-a193-a8752921526c/9b1ace202d31481f00aa83be33a1bef5bc1c9369
/*?sr/bin/true; exec /usr/bin/env nix-shell -p go --run "go run $0" #*/
// summary : go defer trap
// keywords : go, defer, @testable
// publish : gist
// authors : David Crosson
// license : Apache NON-AI License Version 2.0 (https://raw.githubusercontent.com/non-ai-licenses/non-ai-licenses/main/NON-AI-APACHE2)
// id : 613fc74b-18b9-4df3-a193-a8752921526c
// created-on : 2025-03-27T10:06:35+01:00
// managed-by : https://github.com/dacr/code-examples-manager
// run-with : nix-shell -p go --run "go run $file"
@dacr
dacr / concurrency-goroutines-atomics.go
Created March 28, 2025 09:02
go routines atomics / published by https://github.com/dacr/code-examples-manager #21f820ec-141e-4ca2-808d-3dfde9948b0c/52e1141bb0c8bdd599f992fcd4d74e6a0456b363
/*?sr/bin/true; exec /usr/bin/env nix-shell -p go --run "go run $0" #*/
// summary : go routines atomics
// keywords : go, goroutines, atomics, @testable
// publish : gist
// authors : David Crosson
// license : Apache NON-AI License Version 2.0 (https://raw.githubusercontent.com/non-ai-licenses/non-ai-licenses/main/NON-AI-APACHE2)
// id : 21f820ec-141e-4ca2-808d-3dfde9948b0c
// created-on : 2025-03-27T15:36:24+01:00
// managed-by : https://github.com/dacr/code-examples-manager
// run-with : nix-shell -p go --run "go run $file"
@dacr
dacr / list.nix
Created March 28, 2025 09:02
nix list / published by https://github.com/dacr/code-examples-manager #729edcf0-c5d4-41cd-a977-541f4399952f/8bf8bc3870a4c915635976486c4e3cdd8a698a02
## summary : nix list
## keywords : nix, list
## publish : gist
## authors : David Crosson
## license : Apache NON-AI License Version 2.0 (https://raw.githubusercontent.com/non-ai-licenses/non-ai-licenses/main/NON-AI-APACHE2)
## id : 729edcf0-c5d4-41cd-a977-541f4399952f
## created-on : 2025-02-07T17:36:39+01:00
## managed-by : https://github.com/dacr/code-examples-manager
## run-with : nix eval --file $file
#### run-with : nix-instantiate --eval $file
@dacr
dacr / casts-conversions.go
Created March 28, 2025 09:02
go casts and conversions / published by https://github.com/dacr/code-examples-manager #53641fce-d636-4b1b-b4b4-78a6c5f95133/79251b5ebfba9df81e10390f5f57ec4593f363d2
/*?sr/bin/true; exec /usr/bin/env nix-shell -p go --run "go run $0" #*/
// summary : go casts and conversions
// keywords : go, casts, conversions, @testable
// publish : gist
// authors : David Crosson
// license : Apache NON-AI License Version 2.0 (https://raw.githubusercontent.com/non-ai-licenses/non-ai-licenses/main/NON-AI-APACHE2)
// id : 53641fce-d636-4b1b-b4b4-78a6c5f95133
// created-on : 2025-03-27T14:06:42+01:00
// managed-by : https://github.com/dacr/code-examples-manager
// run-with : nix-shell -p go --run "go run $file"
@dacr
dacr / concurrency-goroutines.go
Created March 28, 2025 09:02
go routines / published by https://github.com/dacr/code-examples-manager #3052509b-a36e-42d4-a6f9-6aff6b7d6d6e/fc322bb9972612be3fa40b808783ba4280081bcc
/*?sr/bin/true; exec /usr/bin/env nix-shell -p go --run "go run $0" #*/
// summary : go routines
// keywords : go, goroutines, @testable
// publish : gist
// authors : David Crosson
// license : Apache NON-AI License Version 2.0 (https://raw.githubusercontent.com/non-ai-licenses/non-ai-licenses/main/NON-AI-APACHE2)
// id : 3052509b-a36e-42d4-a6f9-6aff6b7d6d6e
// created-on : 2025-03-27T14:28:34+01:00
// managed-by : https://github.com/dacr/code-examples-manager
// run-with : nix-shell -p go --run "go run $file"
@dacr
dacr / concurrency-channels-select.go
Created March 28, 2025 09:02
go channels select / published by https://github.com/dacr/code-examples-manager #686a22d1-9224-49ea-be72-1c8371cfc9f4/b9bc9db8efa12f47714594462867dc18894058ab
/*?sr/bin/true; exec /usr/bin/env nix-shell -p go --run "go run $0" #*/
// summary : go channels select
// keywords : go, channels, @testable
// publish : gist
// authors : David Crosson
// license : Apache NON-AI License Version 2.0 (https://raw.githubusercontent.com/non-ai-licenses/non-ai-licenses/main/NON-AI-APACHE2)
// id : 686a22d1-9224-49ea-be72-1c8371cfc9f4
// created-on : 2025-03-27T16:43:12+01:00
// managed-by : https://github.com/dacr/code-examples-manager
// run-with : nix-shell -p go --run "go run $file"