- Install this tool to set
$XDG_RUNTIME_DIRautomatically
xbps-install -S dumb_runtime_dir
or
| #!/usr/bin/env python3 | |
| # NOTE: this script is deprecated; | |
| # maintained version with SVG icons: https://github.com/glowinthedark/index-html-generator/ | |
| # --- | |
| # Copyright 2020 glowinthedark | |
| # | |
| # Licensed under the Apache License, Version 2.0 (the "License"); | |
| # you may not use this file except in compliance with the License. |
| package sse | |
| import ( | |
| "encoding/json" | |
| "fmt" | |
| "github.com/alexandria-oss/core" | |
| "github.com/go-kit/kit/log" | |
| "net/http" | |
| "sync" | |
| ) |
| /* eslint-__ENV node */ | |
| /* eslint no-use-before-define: [0, "nofunc"] */ | |
| "use strict"; | |
| // sources of inspiration: | |
| // https://web-identity-federation-playground.s3.amazonaws.com/js/sigv4.js | |
| // http://docs.aws.amazon.com/AmazonS3/latest/API/sigv4-query-string-auth.html | |
| var crypto = require("k6/crypto"); | |
| function createCanonicalRequest( |
In order to get a general idea of how k6 is performing, and to see if there are any low-hanging fruit in terms of optimizations we could do, I did a series of tests running k6 against a local server, testing different changes to the k6 code base.
macOS High Sierra 10.13.13
MacBook Pro(Retina, 15-inch, Mid 2014)
Processor: 2,2Ghz Intel Core i7
Memory: 16GB 1600MHz DDR3
| /* | |
| Forked from https://gist.github.com/arantius/3123124 | |
| The MIT License (MIT) | |
| Copyright (c) 2014 Anthony Lieuallen | |
| Permission is hereby granted, free of charge, to any person obtaining a copy | |
| of this software and associated documentation files (the "Software"), to deal | |
| in the Software without restriction, including without limitation the rights | |
| to use, copy, modify, merge, publish, distribute, sublicense, and/or sell |
| #!/bin/bash | |
| # Main credit goes to joostrijneveld on github: | |
| # Ref: https://gist.github.com/joostrijneveld/59ab61faa21910c8434c | |
| # adopted to "I want to have a pdf with a textual AND QR key to directly | |
| # print it and put it in the bank safe" needs by Jan Stuehler, | |
| # 2015-10-05. | |
| if [ $# -lt 2 ] | |
| then | |
| echo "Please specify [Key ID] and an arbitrary [Name]" |
| ;; I am not a regular emacs user and haven't played with lisp for many years. | |
| ;; I struggled for a couple of days trying to tweak org-capture-templates to | |
| ;; get my desired behavior for journal entries. I hope this helps someone! | |
| ;; | |
| ;; I have been following the excellent guide http://doc.norang.ca/org-mode.html | |
| ;; The "journal" template was the one I wanted to tweak. I use a date-based | |
| ;; journal filename, e.g. "2015-09-22-Journal-Entry.org". The contents of the | |
| ;; file consist of a top-level headline with a human-friendly date, followed | |
| ;; by second-level headline with the time and brief journal note. For example: | |
| ;; |
| window.console.loge = function (msg) { | |
| var gifs = ['wink','shake-space','peepers','prizza','hat','gradient','fat','rainbow','sunglasses','derp','shake'], | |
| wow = ['', 'wow! ', 'amaze! ', 'dazzle! '], | |
| adjs = ['so', 'such', 'many', 'much', 'very'], | |
| randomizr = function (a) { return a[Math.floor(Math.random() * a.length)];}, | |
| message = '%c ' + randomizr(wow) + randomizr(adjs) + ' ' + typeof msg + ': ', | |
| css = 'background: url(http://d1e3ezyatlol8u.cloudfront.net/img/212/doge-' + randomizr(gifs) + '-212.gif) no-repeat 0 0; background-size: 80px 80px; font-family: \'Comic Sans MS\', cursive; text-shadow: 0 1px 1px rgba(0,0,0,1); font-size: 14px; padding: 25px; line-height: 70px; color: #fff; font-weight: 100;'; | |
| console.log.apply(console, typeof msg === 'object' ? [message, css, msg] : [message += msg, css]); | |
| }; |
| #!/usr/bin/python | |
| import ast, _ast, os | |
| for root, dirs, files in os.walk('.'): | |
| for name in files: | |
| if name.endswith('.py'): | |
| full = os.path.join(root, name) | |
| t = ast.parse(open(full).read()) | |
| for n in ast.walk(t): | |
| if isinstance(n, _ast.Str) and not isinstance(n.s, unicode): |