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
| #!/usr/bin/perl -w | |
| use strict; | |
| $|=1; | |
| if ($#ARGV != 3) { | |
| print STDERR "Usage: genetic_regex.pl file_with_passing_lines file_with_failing_lines {file_with_hints|''} {file_with_bans|''} \n"; | |
| print STDERR "Created by Vitaly '_Vi' Shukela, in 2014. License is LGPLv2+.\n"; | |
| exit 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
| R! 16.0403 l=4 PPCG | |
| R! 15.0236 l=2 ^P | |
| R! 14.0646 l=6 ^[P^]P | |
| R! 13.0919 l=9 [^?][PG]$ | |
| R! 12.1617 l=16 (?<!\\..)(?!]).$ | |
| R! 8.19108 l=19 ^[\w^]*$|!|]P|G]\$$ | |
| R! 8.17125 l=17 !|[^?]P(CG|G..)?$ | |
| R! 5.25195 l=25 !|((G.|P|\.)\$|[^?]P|CG)$ | |
| R! 4.2402 l=24 ^[(!P]|G..$|]..\||[^?]P$ | |
| R! 3.29278 l=29 ^.{3,23}[.-~]..\$$|[^P?][PG]$ |
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
| /* | |
| directfbtext, implemented by Vitaly "_Vi" Shukela in 2014. | |
| Based on: | |
| DirectFB Tutorials | |
| (c) Copyright 2000-2002 convergence integrated media GmbH. | |
| (c) Copyright 2002 convergence GmbH. | |
| All rights reserved. |
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
| #!/bin/bash | |
| if [ -z "$2" ]; then | |
| echo "Usage: copy_with_links one_or_more_source_files target_directory/" | |
| exit 1 | |
| fi | |
| set -e | |
| f=("$@") |
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 <stdio.h> | |
| void hash(const unsigned char* buf, size_t len, unsigned long long *hash1, unsigned long long *hash2) | |
| { | |
| unsigned long long &h=*hash1; | |
| unsigned long long &j=*hash2; | |
| size_t l = len; | |
| const unsigned char* b = buf; | |
| h=0xC0CC3051F486B191; |
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
| #!/usr/bin/perl | |
| # Removes alpha channel from BPG v0.9.3- image, so it can be decoded with libbpg v0.9.4+. | |
| # Implemented by Vitaly "_Vi" Shukela in 2015 | |
| # License: MIT | |
| read STDIN,$_,4; | |
| my $magic=unpack("N", $_); | |
| printf STDERR "magic: %08X\n", $magic; | |
| print STDOUT pack("N", $magic); |
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 <sys/eventfd.h> | |
| #include <unistd.h> | |
| #include <stdlib.h> | |
| #include <stdio.h> | |
| #include <stdint.h> | |
| #include <string.h> | |
| #include <errno.h> | |
| #include <fcntl.h> | |
| // Implemented by Vitaly "_Vi" Shukela in 2015, License=MIT. |
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
| #!/bin/bash | |
| # vmtouchpoll: Keep some files locked in memory (including new files, dropping deleted files) | |
| # Usage: vmtouchpoll '/path/to/some/files/*.idx' | |
| # Works by periodically restarting vmtouch with a new set of files | |
| # Implemented by Vitaly "_Vi" Shukela in 2015, License=MIT | |
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
| #define _GNU_SOURCE 1 | |
| #include <stdio.h> | |
| #include <stdlib.h> | |
| #include <unistd.h> | |
| #include <sys/types.h> | |
| #include <dlfcn.h> | |
| #include <sys/time.h> | |
| #include <sys/select.h> | |
| #include <time.h> | |
| #include <sys/stat.h> |
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
| #define _GNU_SOURCE 1 | |
| #include <stdio.h> | |
| #include <stdlib.h> | |
| #include <unistd.h> | |
| #include <sys/types.h> | |
| #include <dlfcn.h> | |
| #include <errno.h> | |
| static int (*orig_llseek)( | |
| unsigned int fd, unsigned long offset_high, |