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
import Text.XML.HXT.Core | |
import Data.Maybe | |
mkAbsRefs | |
:: ArrowXml a | |
=> String -> a XmlTree XmlTree | |
mkAbsRefs base = | |
processTopDown | |
(editRef "a" "href" -- (2) | |
>>> |
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
{-# LANGUAGE TypeSynonymInstances #-} | |
{-# LANGUAGE FlexibleInstances #-} | |
{-# LANGUAGE OverloadedStrings #-} | |
{-# OPTIONS_GHC -fno-warn-orphans #-} | |
-- | Lucid support for Yesod. | |
-- | |
-- Example Handler for a route, using Lucid to generate html, | |
-- including a rendered url: | |
-- |
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
{-# LANGUAGE OverloadedStrings #-} | |
{-# LANGUAGE DeriveDataTypeable #-} | |
module Main where | |
import Lib | |
import System.Environment (getArgs) | |
import Database.SQLite.Simple | |
import System.Console.CmdArgs | |
import Data.List |
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
import Html exposing (..) | |
import Html.Attributes exposing (..) | |
import Html.Events exposing (..) | |
import Http | |
import Json.Decode as Decode | |
main : Program Never Model Msg | |
main = | |
Html.program |
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
module Main exposing (..) | |
import Html exposing (..) | |
import Html.Attributes exposing (..) | |
import Html.Events exposing (..) | |
type alias Model = | |
{ tweets : List String | |
, new_tweet : String | |
} |
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
{% if is_paginated %} | |
<nav aria-label="Page navigation example"> | |
<ul class="pagination justify-content-left"> | |
{% if page_obj.has_previous %} | |
<li class="page-item"><a class="page-link" href="?page={{ page_obj.previous_page_number }}">«</a></li> | |
{% else %} | |
<li class="page-item disabled"><a class="page-link" href="#"><span>«</span></a></li> | |
{% endif %} | |
{% for i in paginator.page_range %} | |
{% if page_obj.number == i %} |
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
https://codepoets.co.uk/2012/irssi-crapbuster-cleaning-up-the-irc-window/ | |
install crapbuster.pl in ~/.irssi/scripts | |
configure it with: | |
/load crapbuster.pl | |
/set crapbuster_levels JOINS PARTS QUITS NICKS CLIENTCRAP CRAP MODE TOPICS KICKS | |
then run /crapbuster in the window you want to clean up. |
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
export PATH="${PATH}:$HOME/bin:$HOME/.local/bin:$HOME/go/bin" |
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
# on t420s | |
rmmod iwldvm | |
rmmod iwlwifi |