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 NoImplicitPrelude #-} | |
{-# LANGUAGE OverloadedRecordDot #-} | |
{-# LANGUAGE DuplicateRecordFields #-} | |
{-# LANGUAGE QuasiQuotes #-} | |
module App where | |
import Verset | |
import Control.Exception.Safe (throwString, bracket) |
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 NoImplicitPrelude #-} | |
{-# LANGUAGE OverloadedRecordDot #-} | |
{-# LANGUAGE DuplicateRecordFields #-} | |
{-# LANGUAGE QuasiQuotes #-} | |
module App where | |
import Verset | |
import qualified Data.Aeson as Ae |
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 NoImplicitPrelude #-} | |
{-# LANGUAGE OverloadedRecordDot #-} | |
{-# LANGUAGE DuplicateRecordFields #-} | |
{-# LANGUAGE QuasiQuotes #-} | |
module App where | |
import Verset | |
import qualified Data.Aeson as Ae |
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 NoImplicitPrelude #-} | |
{-# LANGUAGE OverloadedRecordDot #-} | |
{-# LANGUAGE DuplicateRecordFields #-} | |
{-# LANGUAGE QuasiQuotes #-} | |
module App where | |
import Verset | |
import qualified Data.Aeson as Ae |
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
open System.Threading.Tasks | |
open DSharpPlus | |
let discord = | |
new DiscordClient( | |
new DiscordConfiguration( | |
Token = "xxxx", //Token goes here | |
TokenType = TokenType.Bot, | |
Intents = DiscordIntents.AllUnprivileged |
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
#Per pane floating window | |
#Toggle with ` (grave) key | |
bind ` if-shell "echo '#{session_name}' | grep -q 'fterm-'" { | |
detach-client | |
} { | |
run-shell "tmux popup -E 'tmux attach -t fterm-#{session_name}-#{pane_id} || tmux new -s fterm-#{session_name}-#{pane_id}'" | |
} |
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 NoImplicitPrelude #-} | |
{-# LANGUAGE OverloadedStrings #-} | |
{-# LANGUAGE ScopedTypeVariables #-} | |
{-# LANGUAGE NumericUnderscores #-} | |
{-# LANGUAGE RankNTypes #-} | |
module Rabbit | |
( defaultOpts | |
, mkConnection | |
, runTopicConsumer |
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 Protolude | |
import qualified Network.HTTP.ReverseProxy as Rp | |
import qualified Network.Wai as W | |
import qualified Network.Wai.Handler.Warp as Wrp | |
import qualified Network.HTTP.Client as HC | |
testProxy :: IO () | |
testProxy = | |
Wrp.run 3000 =<< revProxyApp |
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 Control.Exception.Safe (throwString) | |
import qualified Data.ByteString.Lazy as BSL | |
import qualified Data.Text as Txt | |
import qualified Data.Text.Encoding as TxtE | |
import qualified Network.HTTP.Client as HC | |
import qualified Network.HTTP.Client.MultipartFormData as MFD | |
import Network.HTTP.Req ((/:)) | |
import qualified Network.HTTP.Req as R | |
import qualified System.FilePath as Fp | |
import qualified Text.URI as URI |
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 Data.Conduit ((.|)) | |
import qualified Data.Conduit as C | |
import qualified Data.Conduit.Combinators as C | |
import Network.HTTP.Req ((/:)) | |
import qualified Network.HTTP.Req as R | |
import qualified Network.HTTP.Req.Conduit as R | |
downloadChunkedUrl | |
:: FilePath | |
-> (ByteString -> IO ()) |
NewerOlder