View index.php
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
<?php | |
$fileroot = './cache/'; // Where to store files | |
$ttl = 3600; // Number of seconds to cache a file | |
$fileext = '.gz'; // File extension | |
$lists = [ // Known lists | |
'small' => 'https://small.oisd.nl/', | |
'big' => 'https://big.oisd.nl/', | |
'nsfw' => 'https://nsfw.oisd.nl/' | |
]; |
View program.cs
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
using System; | |
public class Program | |
{ | |
public static void Main() | |
{ | |
// Example: How many /30's can we fit in a /28? | |
var sourcePrefixLength = 28; | |
var destinationPrefixLength = 30; | |
View Program.cs
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
// Use chars from input value with custom iterations | |
WriteAnimatedString("Hello world", 50); | |
Console.WriteLine(); | |
// Use printable ASCII chars with left-to-right effect | |
var chars = Enumerable.Range(32, 127).Select(c => (char)c); | |
WriteAnimatedString("I learned something new today!", animationStyle: AnimationStyle.LeftToRight, chars: chars); | |
Console.WriteLine(); | |
static void WriteAnimatedString( |
View query.sql
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
SELECT `r`.`table_name`, `r`.`referenced_table_name`, `r`.`constraint_name`, GROUP_CONCAT(`k`.`column_name` SEPARATOR ', ') AS `key_columns`, `r`.`delete_rule`, `r`.`update_rule` | |
FROM `information_schema`.`referential_constraints` `r` | |
INNER JOIN `information_schema`.`key_column_usage` `k` on `r`.`constraint_catalog` = `k`.`constraint_catalog` and `r`.`constraint_schema` = `k`.`constraint_schema` and `r`.`constraint_name` = `k`.`constraint_name` | |
WHERE `r`.`constraint_schema` = '<database_name>' | |
GROUP BY `r`.`constraint_catalog`, `r`.`constraint_schema`, `r`.`constraint_name` | |
ORDER BY `r`.`table_name`, `r`.`constraint_name` |
View DecimalValue.cs
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
using System.Linq; | |
namespace YOUR_NAMESPACE_HERE | |
{ | |
public partial class DecimalValue | |
{ | |
public DecimalValue(int[] bits) => Bits.AddRange(bits); | |
public static implicit operator decimal(DecimalValue decimalValue) => decimalValue.ToDecimal(); |
View gist:6a0ed026a4b9bbd2f488fdf7e7841c3e
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
Verifying my Blockstack ID is secured with the address 1LF6MBuM2XTJxAoqCWBHo59ZqQ5EXUaBKs https://explorer.blockstack.org/address/1LF6MBuM2XTJxAoqCWBHo59ZqQ5EXUaBKs |
View custom.css
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
/* Automatisch spoilers tonen bij hover */ | |
div.spoiler:hover { | |
color: white !important; | |
} | |
/* Quotes donkerder dan posts */ | |
.message-quote-div { | |
background-color: #dddede !important; | |
border: 1px solid #c8c8c8 !important; | |
color: #000 !important; |
View DocumentOperationRoleRequirementsFilter.cs
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
using Microsoft.AspNetCore.Authorization; | |
using Swashbuckle.AspNetCore.Swagger; | |
using Swashbuckle.AspNetCore.SwaggerGen; | |
using System.Linq; | |
using System.Reflection; | |
using System.Web; | |
namespace MyNameSpace { | |
public class DocumentOperationRoleRequirementsFilter : IOperationFilter | |
{ |
View gameconsole.cs
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
using Microsoft.Win32.SafeHandles; | |
using System; | |
using System.Diagnostics; | |
using System.IO; | |
using System.Runtime.InteropServices; | |
using System.Threading; | |
namespace ConsoleEngine | |
{ |
NewerOlder