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
| Description="Virtualbox Routed Bridge" | |
| Interface=vnet0 | |
| Connection=bridge | |
| IP=static | |
| BindsToInterfaces=() | |
| Address=172.32.0.1/24 | |
| ExecUpPost="iptables -t nat -I POSTROUTING -s 172.32.0.0/24 -j MASQUERADE || true" | |
| ExecDownPre="iptables -t nat -D POSTROUTING -s 172.32.0.0/24 -j MASQUERADE || true" |
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/sh | |
| # | |
| # Automatically calculate and set xinput coordinate transformation matrix | |
| # for all matching devices listed in DEVICES array | |
| # | |
| # usage: | |
| # ./xinput-automatrix.sh | |
| # | |
| # Mark Riedesel <[email protected]> | |
| # |
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 <iostream> | |
| #include <string> | |
| #include <vector> | |
| #define DEF(_name_) _name_, | |
| typedef enum { | |
| #include "types_defs.h" | |
| MAX_TYPES, | |
| } Types; |
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
| #!/sbin/openrc-run | |
| name=$RC_SVCNAME | |
| command="/usr/bin/autossh" | |
| pidfile="/run/${RC_SVCNAME}.pid" | |
| AUTOSSH_LOGFILE="${AUTOSSH_LOGFILE:-/var/log/${RC_SVCNAME}.log}" | |
| start_stop_daemon_args="-e AUTOSSH_PIDFILE=\"${pidfile}\" -e AUTOSSH_LOGFILE=\"${AUTOSSH_LOGFILE}\"" | |
| command_args="-M 10984 -N -f -o 'PubkeyAuthentication=yes' -o 'PasswordAuthentication=no' \ | |
| -i /root/.ssh/id_rsa -R 6666:localhost:22 middleman@middleman" |
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 <mutex> | |
| #include <thread> | |
| #include <vector> | |
| #include <iostream> | |
| #include <atomic> | |
| class Scheduler | |
| { | |
| public: |
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
| // (C) 2018 Mark Riedesel <[email protected]> | |
| // http://sensible.website/posts/serializing-tasks-with-c++-metaprogramming/ | |
| // The following code is licensed under the MIT license. | |
| #include <cstdint> | |
| #include <cstring> | |
| #include <iostream> | |
| using CommandId = uint16_t; |
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
| export class AuthService { | |
| private readonly createRequest: AjaxCreationMethod = this.config.createRequest; | |
| private readonly refreshToken$ = this.refreshToken(); | |
| constructor(private readonly config: AuthServiceConfig) {} | |
| authenticate(username: string, password: string): Observable<AjaxResponse> { | |
| return this.createRequest({ | |
| url: '/account/login', | |
| method: 'POST', |
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
| type NewProjectRecord = Omit<Partial<ProjectRecord>, 'id'>; | |
| type DeletableProjectRecord = Pick<ProjectRecord, 'id'>; | |
| export class ProjectsContext { | |
| constructor(private service: ProjectService) {} | |
| private readonly remoteRefresh$ = new BehaviorSubject<void>(null); | |
| private readonly create$ = new Subject<NewProjectRecord>(); | |
| private readonly delete$ = new Subject<DeletableProjectRecord>(); |
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/env sh | |
| # Journal by Mark Riedesel | |
| set -e | |
| SCRIPT_DIR="$( cd "$(dirname $0)" &> /dev/null && pwd )" | |
| EDITOR=${EDITOR:-nvim} | |
| ENTRY_SUBDIR="entries" | |
| ENTRY_DIR="${SCRIPT_DIR}/${ENTRY_SUBDIR}" | |
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
| @tool | |
| extends Node | |
| class_name SimpleSkeletonIK3D | |
| var selected_bone_indices: PackedInt32Array | |
| var bones := [] | |
| var bone_chain_length: float | |
| var bone_lengths: PackedFloat32Array | |
| var bone_origins: PackedVector3Array | |
| var bone_directions: PackedVector3Array |