Skip to content

Instantly share code, notes, and snippets.

View andrzejsliwa's full-sized avatar
🎯
Focusing

Andrzej Śliwa andrzejsliwa

🎯
Focusing
  • VP Engineering / CTO / Architect / Polyglot Dev
  • Remote / Gorzów Wielkopolski POLAND
  • 14:49 (UTC +01:00)
  • X @andrzejsliwa
  • LinkedIn in/andrzejsliwa
View GitHub Profile
[~/c64_learning]$ x64 -warp -autostart /Users/andrzejsliwa/c64_learning/spec/example.spec.prg -console -jamaction 5 -autostartprgmode 0 -moncommands /Users/andrzejsliwa/c64_learning/spec/example.spec.vs -chdir /Users/andrzejsliwa/c64_learning/spec
opening dynamic library libavformat.57.dylib failed! error: dlopen(libavformat.57.dylib, 5): image not found
*** VICE Version 3.1 ***
OS compiled for: MacOS Sierra (10.12)
GUI compiled for: SDL2
CPU compiled for: x86_64
Compiler used: clang 8.1.0
Current OS: *nix
Current CPU: Intel Pentium Pro/II/III/Celeron/Core/Core 2/Atom
@andrzejsliwa
andrzejsliwa / Gemfile
Created June 25, 2020 10:37 — forked from dhh/Gemfile
HEY's Gemfile
ruby '2.7.1'
gem 'rails', github: 'rails/rails'
gem 'tzinfo-data', '>= 1.2016.7' # Don't rely on OSX/Linux timezone data
# Action Text
gem 'actiontext', github: 'basecamp/actiontext', ref: 'okra'
gem 'okra', github: 'basecamp/okra'
# Drivers

Keybase proof

I hereby claim:

  • I am andrzejsliwa on github.
  • I am andrzejsliwa (https://keybase.io/andrzejsliwa) on keybase.
  • I have a public key whose fingerprint is 417D 3556 FCE6 AA43 B09C 74EB 7502 2EB3 BF5D D619

To claim this, I am signing this object:

@andrzejsliwa
andrzejsliwa / Database.fs
Last active March 3, 2022 00:29
Example of proper referencing of FSharp.Data.Npqsql to be able use it from FSI (in project running on dotnetcore)
module Database
open FSharp.Data
open FSharp.Data.Npgsql
[<Literal>]
let example = "Host=localhost;Username=postgres;Database=example;Port=5432"
type Example = NpgsqlConnection<example>
(require '[clojure.string :as s])
(declare print-maze)
;; Maze GENERATION
(defn create-grid [rows cols]
(vec (repeat rows (vec (repeat cols #{})))))
(defn north-of [[row col]] [(dec row) col])
(defn south-of [[row col]] [(inc row) col])
@andrzejsliwa
andrzejsliwa / ConstrainedTypesExamples.fsx
Created August 23, 2018 19:12 — forked from swlaschin/ConstrainedTypesExamples.fsx
Examples of creating constrained types in F#
// General hints on defining types with constraints or invariants
//
// Just as in C#, use a private constructor
// and expose "factory" methods that enforce the constraints
//
// In F#, only classes can have private constructors with public members.
//
// If you want to use the record and DU types, the whole type becomes
// private, which means that you also need to provide:
// * a constructor function ("create").
@andrzejsliwa
andrzejsliwa / .zshrc
Last active July 24, 2018 19:55
improved idea command line launcher
function repl {
current_month=`date +%Y-%m-%B`
filepath="$HOME/Documents/repl-$current_month.cljc"
if [ ! -f $filepath ]; then
touch $filepath
fi
echo "; `date`" >> $filepath
line=`grep --regexp="$" --count "$filepath"`
idea $filepath:$line
}
@andrzejsliwa
andrzejsliwa / SMBDIS.ASM
Created May 5, 2018 15:01 — forked from 1wErt3r/SMBDIS.ASM
A Comprehensive Super Mario Bros. Disassembly
;SMBDIS.ASM - A COMPREHENSIVE SUPER MARIO BROS. DISASSEMBLY
;by doppelganger ([email protected])
;This file is provided for your own use as-is. It will require the character rom data
;and an iNES file header to get it to work.
;There are so many people I have to thank for this, that taking all the credit for
;myself would be an unforgivable act of arrogance. Without their help this would
;probably not be possible. So I thank all the peeps in the nesdev scene whose insight into
;the 6502 and the NES helped me learn how it works (you guys know who you are, there's no
; ___ _ __ ___ __ ___
; / __|_ _ __ _| |_____ / /| __|/ \_ )
; \__ \ ' \/ _` | / / -_) _ \__ \ () / /
; |___/_||_\__,_|_\_\___\___/___/\__/___|
; An annotated version of the snake example from Nick Morgan's 6502 assembly tutorial
; on http://skilldrick.github.io/easy6502/ that I created as an exercise for myself
; to learn a little bit about assembly. I **think** I understood everything, but I may
; also be completely wrong :-)
https://stackoverflow.com/questions/49001329/gdb-doesnt-work-on-macos-high-sierra-10-13-3
How to degrade to gdb 8.0.1:
- Unlink current gdb: brew unlink gdb
- Install gdb 8.0.1: brew install https://raw.githubusercontent.com/Homebrew/homebrew-core/9ec9fb27a33698fc7636afce5c1c16787e9ce3f3/Formula/gdb.rb
- Optional: avoid upgrade gdb with brew pin gdb