Skip to content

Instantly share code, notes, and snippets.

View lkwg82's full-sized avatar

Lars K.W. Gohlke lkwg82

View GitHub Profile
#!/bin/bash
g=gphoto2
function cap(){
$g --capture-image-and-download
}
function config()
{
@lkwg82
lkwg82 / gist:9c8a86f16a89fa657ac5
Created March 12, 2015 20:18
output on install
$ npm install
npm http GET http://registry.npmjs.org/grunt-contrib-concat
npm http GET http://registry.npmjs.org/grunt-contrib-clean
npm http GET http://registry.npmjs.org/grunt-contrib-copy
npm http GET http://registry.npmjs.org/grunt
npm http GET http://registry.npmjs.org/grunt-contrib-cssmin
npm http GET http://registry.npmjs.org/grunt-contrib-watch
npm http GET http://registry.npmjs.org/grunt-filerev
npm http GET http://registry.npmjs.org/grunt-contrib-htmlmin
npm http GET http://registry.npmjs.org/grunt-filerev-replace
import org.springframework.boot.context.embedded.EmbeddedServletContainerCustomizer;
import org.springframework.boot.context.embedded.tomcat.TomcatContextCustomizer;
import org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainerFactory;
import org.springframework.cloud.sleuth.Tracer;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import ch.qos.logback.access.tomcat.LogbackValve;
import ch.qos.logback.core.util.ContextUtil;
import lombok.extern.slf4j.Slf4j;
@lkwg82
lkwg82 / SimplestEmbeddedKafkaIT.java
Created December 20, 2017 22:26
simples embedded Kafka test
import static java.util.concurrent.TimeUnit.MILLISECONDS;
import static org.assertj.core.api.Assertions.assertThat;
import java.util.ArrayList;
import java.util.List;
import java.util.Random;
import java.util.concurrent.ExecutionException;
import org.junit.ClassRule;
@lkwg82
lkwg82 / Readme.md
Last active January 19, 2018 13:23
openshift wrapper

Summary:

Have developer friendly wrapper for openshift with an application-centric perspective.

Rationale:

Avoid steep learning curve to initial learn oc .... commands and concepts. Enable self-service by design.

Goals:

Keybase proof

I hereby claim:

  • I am lkwg82 on github.
  • I am lkwg82 (https://keybase.io/lkwg82) on keybase.
  • I have a public key ASBl04qbPsRW33q1X66G9v8NXX7ILxphWXuhkU5ZY7Dxvgo

To claim this, I am signing this object:

@lkwg82
lkwg82 / anonymize.pl
Last active September 15, 2019 22:08
anonymize syncthing log with config xml
#!perl
use strict;
use warnings;
$| = 1;
# use module
use XML::Simple;
use Data::Dumper;
@lkwg82
lkwg82 / convert-pdf-ocr.sh
Created April 19, 2020 20:22
bash script to use ocrmypdf to convert scanned pdfs without to pdfs with searchable text
#!/bin/bash
set -ex
function convertPdf(){
local file=$1
set -e
echo $file
@lkwg82
lkwg82 / bash-prompt.sh
Created May 3, 2020 18:58
bash prompt with terraform workspace and git info
#!/bin/bash
if [[ ! -f $(brew --prefix)/opt/bash-git-prompt/share/gitprompt.sh ]]; then
echo "installing first time bash-git-prompt"
brew install bash-git-prompt
fi
if [[ -f $(brew --prefix)/opt/bash-git-prompt/share/gitprompt.sh ]]; then
__GIT_PROMPT_DIR=$(brew --prefix)/opt/bash-git-prompt/share