/:-------------:\ simon@simon-ssd
:-------------------:: ---------------
:-----------/shhOHbmp---:\ OS: Fedora 33 (Workstation Edition) x86_64
/-----------omMMMNNNMMD ---: Kernel: 5.9.12-200.fc33.x86_64
:-----------sMMMMNMNMP. ---: Uptime: 1 day, 3 hours, 40 mins
:-----------:MMMdP------- ---\ Packages: 1998 (rpm)
,------------:MMMd-------- ---: Shell: fish 3.1.2
:------------:MMMd------- .---: Resolution: 3840x2160
:---- oNMMMMMMMMMNho .----: WM: i3
View AMD Ryzen 5.md
View README.md
The goal is to server Swagger UI via http://localhost:8080/swagger-ui/
-
Add Maven/Gradle dependency
org.webjars:swagger-ui
– https://search.maven.org/artifact/org.webjars/swagger-ui/3.26.1/jar -
Configure the Jetty
DefaultServlet
:
package at.tbbm.manual_input;
import org.eclipse.jetty.server.Server;
View Application.java
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
package root; | |
import root.resources.HelloResource; | |
import org.eclipse.jetty.server.Server; | |
import org.eclipse.jetty.servlet.ServletContextHandler; | |
import org.eclipse.jetty.servlet.ServletHolder; | |
import org.glassfish.jersey.server.ResourceConfig; | |
import org.glassfish.jersey.servlet.ServletContainer; | |
public class Application { |
View JOSM-IntelliJ.md
This note illustrates how to setup JetBrains IntelliJ IDEA for JOSM development.
Requirements
Guide
- Get the source
- Add project from existing source
- Project Settings / Project:
View .gitignore
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
dist/ | |
node_modules/ |
View en.yaml
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
--- | |
navbar: | |
homepage: 'Navigate to the homepage' | |
user: 'Logged in as {{user}}' | |
load: 'Load {{smart_count}} item |||| Load {{smart_count}} items' |
View git.sh
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
git checkout --orphan new-framework | |
# completely rewrite your application in new framework | |
git merge --strategy=ours --allow-unrelated-histories master | |
git commit-tree -p HEAD^2 -p HEAD^1 -m "Merge branch 'new-framework'" "HEAD^{tree}" | |
git reset --hard $OUTPUT_FROM_PREVIOUS_COMMAND | |
git checkout master | |
git merge --ff-only new-framework |
View find-chocolatey-updates.py
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
import xml.etree.ElementTree as ET | |
import glob | |
import urllib.request | |
import yaml | |
from ansible.playbook.helpers import load_list_of_tasks | |
def get_latest_version(id): | |
url = f'https://chocolatey.org/api/v2/Packages()?$filter=(Id%20eq%20%27{id}%27)%20and%20IsLatestVersion' | |
xml = ET.parse(urllib.request.urlopen(url)) |
View jira2gitlab.py
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
#!/usr/bin/env python2 | |
import requests | |
from requests.auth import HTTPBasicAuth | |
import re | |
from StringIO import StringIO | |
import uuid | |
# Inspired from https://gist.github.com/toudi/67d775066334dc024c24 | |
# Tested on Jira 7.4 and Gitlab 2.2 with Python 2.7 | |
JIRA_URL = 'https://your-jira-url.tld/' |
View colorful.ps1
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
$r = (Get-Random -Maximum 255) | |
$g = (Get-Random -Maximum 255) | |
$b = (Get-Random -Maximum 255) | |
Set-ItemProperty "HKCU:\Control Panel\Colors" -Name Background -Value "$r $g $b" |