Skip to content

Instantly share code, notes, and snippets.

View AttilaVM's full-sized avatar

Attila Molnar AttilaVM

View GitHub Profile
@AttilaVM
AttilaVM / Main.elm
Last active January 12, 2018 02:22
Get initial window size with elm
-- https://ellie-app.com/npWNPSCdNa1/6
module Main exposing (main)
import Element exposing (..)
import Element.Attributes exposing (..)
import Element.Events as Events
import Html
import Json.Decode as Json
import Style exposing (..)
@AttilaVM
AttilaVM / Main.elm
Created January 15, 2018 09:35
Simple style-elements v4 layout
module Main exposing (main)
import Color
import Html exposing (Html)
import Element exposing (..)
import Element.Attributes exposing (center)
import Style exposing (..)
import Style.Color as Color
import Style.Font as Font
@AttilaVM
AttilaVM / Main.elm
Created January 17, 2018 18:07
Basic scrolling with Elm
-- https://ellie-app.com/kbX7gy6LSa1/4
module Main exposing (main)
import Dom.Scroll as S
import Html exposing (Html, div, text)
import Html.Attributes exposing (style)
import Html.Events exposing (..)
import Task
import Json.Decode as Json
module Main exposing (..)
import TimeTravel.Html as TimeTravel
import Nav exposing (init, view, update, subscriptions)
main =
TimeTravel.program
{ init = init
, update = update
@AttilaVM
AttilaVM / config.nix
Created February 12, 2018 17:18
Julia dev environment on NixOS
# Based on nico202's gist
# src: https://gist.github.com/nico202/9377b3b378eab950dc05566e733ea320#file-shell-nix-L1
{
packageOverrides = pkgs : with pkgs; rec {
# other env definitions
julia = pkgs.myEnvFun {
name = "julia";
buildInputs = [
@AttilaVM
AttilaVM / test.svg
Created May 2, 2018 20:35
test.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
#!/bin/bash
set -euo pipefail
catch() {
echo "ERROR $1 occurred on $2"
}
trap 'catch $? $LINENO' ERR
pattern="${1? You must provide a search pattern}"
#!/bin/bash
set -euo pipefail
catch() {
echo "ERROR $1 occurred on $2"
}
trap 'catch $? $LINENO' ERR
pattern="${1? You must provide a search pattern}"