Skip to content

Instantly share code, notes, and snippets.

@ArneBab
ArneBab / gisttest
Created May 21, 2014 06:55
gist test
testgist
@ArneBab
ArneBab / .hgsigs
Last active August 29, 2015 14:17 — forked from seeschloss/hexagons.js
8fb2e1d19eba11e40ffaa70425f1585aeef48fe5 0 iJwEAAEIAAYFAlUPNnMACgkQ3M8NswvBBUixLAP/dujl7lJDpdoR97e52NCmANPaNb3cXCVwoZ96RXyFKXMj4sFp/cN321AoVBcThfHTco2NV02rTRQD9ZzrWIlTC412qezijC8hqBle9w9G1w5JWCIaLUX18vz/MECLj5Y/UQU7mvh8Dd7okfJxvDIYKzw1A6IQxd9hB31SS1xgbbA=
@ArneBab
ArneBab / .gitignore
Last active October 8, 2015 14:39 — forked from wedesoft/.gitignore
Python Scheme integration (libguile)
*.so
*.o
*.html
.*.un~
.*.swp
@ArneBab
ArneBab / flymake-java.el
Created February 1, 2016 09:15 — forked from st63jun/flymake-java.el
Fix flymake+ant problem
;; 素のFlymakeでAntを使うとエラー吐くので,いくつか関数を書き換える必要があるっぽい.
(require 'flymake)
(setq flymake-allowed-file-name-masks
'(("\\.\\(?:c\\(?:pp\\|xx\\|\\+\\+\\)?\\|CC\\)\\'" flymake-simple-make-init)
("\\.xml\\'" flymake-xml-init)
("\\.html?\\'" flymake-xml-init)
("\\.cs\\'" flymake-simple-make-init)
("\\.p[ml]\\'" flymake-perl-init)

Keybase proof

I hereby claim:

  • I am ArneBab on github.
  • I am arnebab (https://keybase.io/arnebab) on keybase.
  • I have a public key whose fingerprint is 6B05 41F0 94FF 2163 6FBA 2433 3307 469B FE96 C404

To claim this, I am signing this object:

@ArneBab
ArneBab / Factors.java
Last active October 12, 2017 08:36 — forked from Smerity/Factors.java
Go vs GCCGO vs Java vs Python vs PyPy for naive factorisation
import java.math.BigInteger;
class Factors {
public static void main (String [] args)
{
// 157 bit n = pq with p ~= 78 bits
BigInteger n = new BigInteger("273966616513101251352941655302036077733021013991");
// Set i to be p - 10e6
BigInteger i = new BigInteger("496968652506233112158689");
(define* (string-replace-substring s substr replacement #:optional (start 0) (end (string-length s)))
"Replace every instance of substring in s by replacement."
(let ((substr-length (string-length substr)))
(if (zero? substr-length)
(error "string-replace-substring: empty substr")
(let loop
((start start)
(pieces (list (substring s 0 start))))
(let ((idx (string-contains s substr start end)))
(if idx
Jul 11, 2018 21:27:31:602 (freenet.client.async.SplitFileFetcherSegmentStorage$1, <noname>(5), ERROR): Failed to decode freenet.client.async.SplitFileFetcherSegmentStorage$1@a012067 because of internal error: java.lang.OutOfMemoryError: Java heap space
java.lang.OutOfMemoryError: Java heap space
at freenet.client.async.SplitFileFetcherSegmentStorage.innerDecode(SplitFileFetcherSegmentStorage.java:489
)
at freenet.client.async.SplitFileFetcherSegmentStorage.access$000(SplitFileFetcherSegmentStorage.java:40)
at freenet.client.async.SplitFileFetcherSegmentStorage$1.start(SplitFileFetcherSegmentStorage.java:304)
at freenet.support.MemoryLimitedJobRunner$1.run(MemoryLimitedJobRunner.java:91)
at freenet.support.PooledExecutor$MyThread.innerRun(PooledExecutor.java:249)
at freenet.support.PooledExecutor$MyThread.realRun(PooledExecutor.java:189)
at freenet.support.io.NativeThread.run(NativeThread.java:156)
@ArneBab
ArneBab / freestream.sh
Last active September 2, 2018 11:04 — forked from bertm/freestream.sh
#!/bin/bash
# This script uses x264 and ffmpeg to recode an input video to low-bitrate MPEG-TS segmented h264
# stream that is suitable for streaming over the web and can be inserted into Freenet.
# Settings have been chosen to strongly prefer quality over encoding speed under conditions of an
# extremely low bitrate, to make the result suitable for direct streaming over Freenet.
#
# (c) bertm, 2014
#
# Prefix for file names in the playlist
@ArneBab
ArneBab / jdee.gradle
Last active September 2, 2018 11:24 — forked from ivv-private/jdee.gradle
jdee.gradle
// use by adding
// apply from:'jdee.gradle'
// to build.gradle
def prj = { project ->
"(jdee-project-file-version" (["1.0"])
"(jdee-set-variables" {
"'(jdee-compile-option-directory" ([project.sourceSets.main.output.classesDir])
"'(jdee-junit-working-directory" ([project.projectDir])