This file contains hidden or 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
| -- ghci haspl.hs | |
| -- do a <- readFile "./kompilator/tests/25.spl"; parseTest splprog a | |
| import Control.Monad (void) | |
| import Data.Void | |
| import Text.Megaparsec | |
| import Text.Megaparsec.Char | |
| import Text.Megaparsec.Expr hiding (Operator) | |
| import Data.List | |
| import qualified Text.Megaparsec.Char.Lexer as L |
This file contains hidden or 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
| ;;; nix-mode.el --- Major mode for editing .nix files -*- lexical-binding: t -*- | |
| ;; Maintainer: Matthew Bauer <mjbauer95@gmail.com> | |
| ;; Homepage: https://github.com/NixOS/nix-mode | |
| ;; Version: 1.2.1 | |
| ;; Keywords: nix, languages, tools, unix | |
| ;; Package-Requires: ((emacs "24.3")) | |
| ;; This file is NOT part of GNU Emacs. |
This file contains hidden or 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
| # Do not modify this file! It was generated by ‘nixos-generate-config’ | |
| # and may be overwritten by future invocations. Please make changes | |
| # to /etc/nixos/configuration.nix instead. | |
| { config, lib, pkgs, ... }: | |
| { | |
| imports = | |
| [ <nixpkgs/nixos/modules/installer/scan/not-detected.nix> | |
| ]; |
This file contains hidden or 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
| Success!! | |
| Congratulations, you have finished the challenge. Below are listings of your last submitted programs. | |
| Program 1 | |
| l1 = h1; | |
| l2 = h2; | |
| l3 = h3; | |
| l4 = h4; | |
| l5 = h5; | |
| l6 = h6; |
This file contains hidden or 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
| node keys.js > ./keys.json | |
| nix eval '(builtins.fromJSON builtins.readFile(./keys.json))' |
This file contains hidden or 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
| # asserts: 64-bit | |
| # auditd running | |
| # sudo auditctl -a exit,always -F arch=b64 -S connect | |
| import codecs, struct, socket, sys, os, re | |
| class AuditLog(object): | |
| def __init__(self): | |
| self.last_event = -1 |
This file contains hidden or 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
| // ==UserScript== | |
| // @name GH-PR-Approvals | |
| // @namespace http://serokell.io | |
| // @version 0.5 | |
| // @updateURL https://gist.githubusercontent.com/yorickvP/e69775e5b8997054103b855aea4103aa/raw/ | |
| // @description adds approval count to github PRs | |
| // @author You | |
| // @match https://github.com/* | |
| // @run-at document-start | |
| // @grant unsafeWindow |
This file contains hidden or 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
| $ postgres --version | |
| postgres (PostgreSQL) 10.1 | |
| # postgresql_jdbc | |
| nix-repl> postgresql_jdbc.src.urls | |
| [ "http://jdbc.postgresql.org/download/postgresql-jdbc-9.3-1100.src.tar.gz" ] | |
| # java | |
| nix-repl> openjdk8.jre.name | |
| "openjdk-8u172b02" |
This file contains hidden or 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
| Mar 14 20:57:57 wiki postgresql-start[635]: 2018-03-14 20:57:57.044 GMT [7545] ERROR: column t1.tgconstrname does not exist at character 113 | |
| Mar 14 20:57:57 wiki postgresql-start[635]: 2018-03-14 20:57:57.044 GMT [7545] STATEMENT: SELECT DISTINCT NULL::text as pnspname, NULL::text as fnspname, c1.relname as prelname, c2.relname as frelname, t1.tgconstrname, a.attnum as keyseq, ic.relname as fkeyname, t1.tgdeferrable, t1.tginitdeferred, t1.tgnargs,t1.tgargs, p1.proname as updaterule, p2.proname as deleterule FROM pg_class c1 JOIN pg_index i ON (c1.oid=i.indrelid) JOIN pg_class ic ON (i.indexrelid=ic.oid) JOIN pg_attribute a ON (ic.oid=a.attrelid), pg_class c2, pg_trigger t1 JOIN pg_proc p1 ON (t1.tgfoid=p1.oid), pg_trigger t2 JOIN pg_proc p2 ON (t2.tgfoid=p2.oid) WHERE (t1.tgrelid=c1.oid AND t1.tgisconstraint AND t1.tgconstrrelid=c2.oid AND p1.proname ~ '^RI_FKey_.*_upd$') AND (t2.tgrelid=c1.oid AND t2.tgisconstraint AND t2.tgconstrrelid=c2.oid AND p2.proname ~ '^RI_FKey_.*_del$') AND i.indisprimary |
This file contains hidden or 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
| #include <ctype.h> | |
| #include <stdio.h> | |
| #include <stdlib.h> | |
| #include <unistd.h> | |
| #include <string.h> | |
| #include "sss.h" | |
| int cli_create(int argc, const char* argv[]) { | |
| if (argc != 4) return 1; | |
| unsigned long int shares = strtoul(argv[2], NULL, 10); | |
| unsigned long int required = strtoul(argv[3], NULL, 10); |