Skip to content

Instantly share code, notes, and snippets.

View ridercz's full-sized avatar
🇨🇿

Michal Altair Valášek ridercz

🇨🇿
View GitHub Profile
#!/bin/sh
### BEGIN INIT INFO
# Provides: <SCRIPT_NAME>
# Required-Start: $local_fs $network $named $time $syslog
# Required-Stop: $local_fs $network $named $time $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Description: Script to run asp.net 5 application in background
### END INIT INFO
@ridercz
ridercz / AcmePOC.cs
Last active January 15, 2017 17:14
Certes ACME client POC
using System;
using System.IO;
using System.Linq;
using System.Security.Cryptography.X509Certificates;
using System.Threading.Tasks;
using Certes;
using Certes.Acme;
using Certes.Pkcs;
namespace AcmePOC {
using System;
using System.Collections.Generic;
using System.Linq;
public class Program {
public static void Main() {
// Test data
byte[] prefix = { 0xDE, 0xAD, 0xBE, 0xEF }; // 4 bytes
byte[] block1 = { 0xAA, 0xAA, 0xAA, 0xAA }; // 4 bytes
byte[] block2 = { 0xBB, 0xBB, 0xBB, 0xBB, 0xBB, 0xBB, 0xBB, 0xBB, }; // 8 bytes
@ridercz
ridercz / keybase.md
Created July 12, 2018 11:47
Keybase proof

Keybase proof

I hereby claim:

  • I am ridercz on github.
  • I am ridercz (https://keybase.io/ridercz) on keybase.
  • I have a public key ASAHzRzIu8FjooJ67Avq-ksBi3C0TD8SBxZBOc5A4iB1rwo

To claim this, I am signing this object:

@ridercz
ridercz / rotate_splice.scad
Created March 6, 2019 17:56
Limiting angles of rotate_extrude in OpenSCAD 2015.3
intersection() {
rotate_extrude() {
translate([20, 0]) circle(5, $fn = 16);
}
translate([0, 0, -5]) linear_extrude(10) rotate_splice(5, 20, 50);
}
module rotate_splice(count, angle_length, radius) {
for(i = [0:count - 1]) {
angle_begin = 360 / count * i;
@ridercz
ridercz / Program.cs
Created April 11, 2019 00:56
Card printer
using System;
using System.Drawing;
using System.Drawing.Printing;
using System.IO;
using System.Linq;
using System.Threading;
namespace CardPrinter {
class Program {
private const string FOLDER_PATH = @"D:\Downloads\badges\Avers";
@ridercz
ridercz / water_mill.scad
Last active September 25, 2019 20:33
Water mill toy 3D model OpenSCAD source
/******************************************************************************
* WATER MILL TOY version 1.0 (2019-09-24)
* Copyright (c) Michal Altair Valasek, 2019, licensed under CC BY-NC-SA
* www.rider.cz | www.altair.blog
*****************************************************************************/
/* OSBS:build */ // enable https://github.com/ridercz/OSBS
/* [Common] */
side_width = 100;
@ridercz
ridercz / water_mill-side_a.stl
Created September 25, 2019 20:33
Water mill toy 3D model STL
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@ridercz
ridercz / _rnav.scss
Created January 2, 2020 12:29
Simple SCSS responsive menu
/*
$WidthStop: maximum width for collapsed menu
$Padding: general padding value
$ItemSpacing: spacing between items of horizontal menu
$Color: foreground color
$BackColor: background color
$HoverColor: foreground color for hover state
$HoverBackColor: background color for hover state
$WideAlign content alignment in wide mode
$NarrowAlign: content alignment in narrow mode
@ridercz
ridercz / gsch.scad
Created February 12, 2020 16:58
Gopas Suction Cup Holder
/****************************************************************************
* SUCTION CUP HOLDER version 1.0 (2020-02-11) *
* Copyright (c) Michal Altair Valasek, 2020 *
* www.rider.cz | www.altair.blog *
****************************************************************************/
/* [General] */
inner_diameter = 56;
height = 30;
wall_thickness = 1.67;