Skip to content

Instantly share code, notes, and snippets.

View skurfuerst's full-sized avatar
😀

Sebastian Kurfürst skurfuerst

😀
View GitHub Profile
@skurfuerst
skurfuerst / gen-types.mjs
Created January 16, 2021 21:10
Generate runtypes from TypeScript definitions using ts-morph
// RUN with a recent node.js version, using "node gen-types.mjs"
// DEPENDS on typescript and ts-morph
import { Project } from "ts-morph";
import { writeFileSync } from "fs";
const project = new Project({
tsConfigFilePath: "tsconfig.json",
});
@skurfuerst
skurfuerst / dev.sh
Created December 27, 2023 15:15
Testing Kubernetes Environments via k3s and k3sup on Hetzner Cloud via the hcloud CLI
#!/bin/bash
############################## DEV_SCRIPT_MARKER ##############################
# This script is used to document and run recurring tasks in development. #
# #
# You can run your tasks using the script `./dev some-task`. #
# You can install the Sandstorm Dev Script Runner and run your tasks from any #
# nested folder using `dev run some-task`. #
###############################################################################
set -e
@skurfuerst
skurfuerst / CustomThrowableStorage.php
Created October 5, 2023 11:29
Custom Throwable Storage to prevent exceptions
<?php
namespace MyPackage\Site;
use Neos\Flow\Log\ThrowableStorage\FileStorage;
use Neos\Media\Exception\NoThumbnailAvailableException;
/*
After implementing Kaleidoscope for Images and SourceSets we got an uncontrollably growing exception folder
@skurfuerst
skurfuerst / build.sh
Last active October 11, 2022 09:28
GitLab and Rancher 2 Authentication Proxy
#!/bin/bash
set -ex
go build -o rancher_gitlab_proxy main.go
GOOS=linux go build -o rancher_gitlab_proxy_linux main.go
<?php
namespace My\Package\Command;
use Neos\ContentRepository\Domain\Model\NodeInterface;
use Neos\ContentRepository\Domain\Service\ContextFactoryInterface;
use Neos\ContentRepository\Domain\Service\NodeServiceInterface;
use Neos\Flow\Cli\CommandController;
use Neos\Flow\Annotations as Flow;
### Keybase proof
I hereby claim:
* I am skurfuerst on github.
* I am skurfuerst (https://keybase.io/skurfuerst) on keybase.
* I have a public key ASDTRmPo5bjrl-KEiVuvtxPSJvkgbSCeYXMk_-817HKbcAo
To claim this, I am signing this object:
@skurfuerst
skurfuerst / composer.json
Created October 24, 2016 17:52
composer.json fluid standalone
{
"name": "neos/neos-development-distribution",
"description" : "Neos Development Distribution",
"license": "GPL-3.0+",
"support": {
"email": "hello@neos.io",
"slack": "http://slack.neos.io/",
"forum": "https://discuss.neos.io/",
"wiki": "https://discuss.neos.io/c/the-neos-project/project-documentation",
"issues": "https://jira.neos.io/browse/NEOS",
@skurfuerst
skurfuerst / SerializableMixin.coffee
Created January 5, 2014 11:42
SerializableMixin for Ember.JS
define [
'lib/ember'
], (
E
) ->
# # SerializableMixin
#
# Makes persistent parts of an `Ember.Object` serializable and deserializable into a string:
#
editPreviewModes:
## ORIGINAL (Aske's Patch)
inPlace:
editingMode: TRUE
previewMode: FALSE
renderingMode: 'default'
title: 'In-place'
position: 100
env[FLOW_ROOTPATH] = /var/www/new_sandstorm_website/flow/releases/current/
env[FLOW_WEBPATH] = /var/www/new_sandstorm_website/htdocs/
env[FLOW_CONTEXT] = Production
env[FLOW_REWRITEURLS] = 1'
includeDefaultConfiguration false
extraConfiguration '
location ~ "^/_Resources/Persistent/" {
rewrite "(.{40})/.+\.(.+)" /_Resources/Persistent/$1.$2 break;