Skip to content

Instantly share code, notes, and snippets.

Avatar

Werner Robitza slhck

View GitHub Profile
@slhck
slhck / word-to-json-string.sh
Created Nov 12, 2020
Convert a Word document to a Markdown-formatted JSON-parsable string
View word-to-json-string.sh
#!/usr/bin/env bash
#
# Convert a Word document to a Markdown-formatted JSON-parsable string
pandoc "$1" -t gfm-raw_html --wrap=preserve -o - | python -c 'import json; import sys; print(json.dumps(sys.stdin.read()))'
@slhck
slhck / ffmpeg-progress.py
Created Oct 17, 2020
Run an ffmpeg command and get the progress in percent
View ffmpeg-progress.py
#!/usr/bin/env python3
#
# Run an ffmpeg command with a progress iterator
# Author: Werner Robitza
# Based on: https://gist.github.com/Hellowlol/5f8545e999259b4371c91ac223409209
# License: MIT
import subprocess
import re
from typing import Iterator
@slhck
slhck / diagnostics.txt
Created Jul 15, 2020
RStudio diagnostics
View diagnostics.txt
RStudio Diagnostics Report
==========================
WARNING: This report may contain sensitive security information and / or
personally identifiable information. Please audit the below and redact any
sensitive information before submitting your diagnostics report.
Generated: Wed Jul 15 08:58:21 2020
View pyproject.toml
[tool.poetry]
name = "test"
version = "0.1.0"
description = ""
authors = ["Werner Robitza <werner.robitza@gmail.com>"]
[tool.poetry.dependencies]
python = "^3.8"
ffmpeg_bitrate_stats = { git = "ssh://git@github.com:slhck/ffmpeg-bitrate-stats.git" }
@slhck
slhck / release.sh
Created Jan 16, 2020
A simple release script for Python projects
View release.sh
#!/bin/bash
#
# Bump the version, run auto-changelog, and push to Git
#
# Based on:
# - https://gist.github.com/pete-otaqui/4188238
# - https://gist.github.com/mareksuscak/1f206fbc3bb9d97dec9c
#
# Requirements:
# - `npm i -g auto-changelog`
View cloudSettings
{"lastUpload":"2021-01-22T10:04:05.409Z","extensionVersion":"v3.4.3"}
@slhck
slhck / # libvmaf - 2019-04-12_08-37-31.txt
Created Apr 13, 2019
libvmaf on 4.9.125-linuxkit - Homebrew build logs
View # libvmaf - 2019-04-12_08-37-31.txt
Homebrew build logs for libvmaf on 4.9.125-linuxkit
Build date: 2019-04-12 08:37:31
@slhck
slhck / # ffmpeg - 2019-03-22_09-26-56.txt
Created Mar 22, 2019
ffmpeg on Ubuntu 18.10 - Homebrew build logs
View # ffmpeg - 2019-03-22_09-26-56.txt
Homebrew build logs for ffmpeg on Ubuntu 18.10
Build date: 2019-03-22 09:26:56
@slhck
slhck / # autogen - 2019-03-02_14-14-08.txt
Created Mar 2, 2019
autogen on Ubuntu 18.10 - Homebrew build logs
View # autogen - 2019-03-02_14-14-08.txt
Homebrew build logs for autogen on Ubuntu 18.10
Build date: 2019-03-02 14:14:08
@slhck
slhck / # shared-mime-info - 2019-02-13_08-53-25.txt
Created Feb 13, 2019
shared-mime-info on Ubuntu 18.10 - Homebrew build logs
View # shared-mime-info - 2019-02-13_08-53-25.txt
Homebrew build logs for shared-mime-info on Ubuntu 18.10
Build date: 2019-02-13 08:53:25