Skip to content

Instantly share code, notes, and snippets.

View bigos's full-sized avatar

Jacek Podkanski bigos

  • North West England
View GitHub Profile
@bigos
bigos / simplified-haskell-install.org
Last active November 29, 2022 03:34
My way of installing Haskell on Windows so that I can build gi-gtk based stack projects

Simplified installation

already I have

choco msys2 emacs

Install GHC

open cmd as administrator

Press Windows button, in ‘Type to search’ type cmd, right-click on Command Promp Desktop app and select Run as administrator.

lines to paste in cmd

{-# LANGUAGE OverloadedStrings #-}
module Main where
import qualified GI.Gtk as GI (init,
main)
import GI.Gtk (boxNew,
binGetChild,
boxPackStart,
checkButtonNew,
@bigos
bigos / trees.lisp
Created December 29, 2017 04:20
Experiment with tree traversal in Lisp
;;; tree traversal
(defparameter tr '((s
(num
(dig
(1))
(diga
(da
(2a))
(da
@bigos
bigos / README.md
Created June 18, 2018 11:57 — forked from cypriss/README.md
Rails 2.3.14 Ruby 1.9.3 - Monkey Patches

How we upgraded UserVoice, a Rails 2.3.14 app, to Ruby 1.9.3.

Blog post here

@bigos
bigos / Main.elm
Last active August 16, 2018 22:31
Elm code for parsing json data
module Main exposing (..)
import Html exposing (Html, text, div, h1, img, p, ul, li, hr)
import Html.Attributes exposing (src)
import Json.Decode exposing (..)
import ISO8601
---- MODEL ----
@bigos
bigos / nestedIfs.hs
Created August 26, 2018 23:51
problem with nesting if statements in haskell
check_if_proceed configFolders = do
let emacsdf = "/home/jacek/.emacs.d"
traceM ("calling check_if_proceed " ++ show ("ccc",configFolders))
exists <- doesDirectoryExist emacsdf
symlink <- pathIsSymbolicLink emacsdf
let confemp = configFolders == []
let result = False
if exists
then do
{
@bigos
bigos / Java8netbeans.org
Created September 4, 2018 20:16
Java 8 and Netbeans

Java

Assumptions

This write-up assumes Ubuntu 18.04 or similar, with OpenJDK installed

links

jacek@jacek-ixtreme-M5850:~/Desktop$ ls -al /usr/bin/java
lrwxrwxrwx 1 root root 22 Jul  9 20:09 /usr/bin/java -> /etc/alternatives/java
@bigos
bigos / elm-turbolinks.org
Created October 26, 2018 10:56
Description of my attempt to make turbolinks play nicely with elm
#!/usr/local/bin/sbcl --script
(define-alien-routine gtk_application_window_new (* t) (app (* t)))
(define-alien-routine gtk_application_new (* t) (txt c-string) (flags int))
(define-alien-routine g_application_run int
(app (* t)) (argc int) (argv (* t)))
(define-alien-routine g_signal_connect_data int ;

Installing SBCL from source on Windows

This tutorial assumes you have installed binary version of SBCL downloaded from http://www.sbcl.org/platform-table.html

Also, it assumes you have Msys2 installed. https://www.msys2.org/ And all the tools needed for compilation are there.

On top of that I used Windows cmd started from a bat file that adds Msys2 paths.