Skip to content

Instantly share code, notes, and snippets.

View JesperDramsch's full-sized avatar
🤓
This mind is intentionally left blank.

Jesper Dramsch JesperDramsch

🤓
This mind is intentionally left blank.
View GitHub Profile
@JesperDramsch
JesperDramsch / PromaxFlowMove.sh
Last active December 23, 2015 10:49
This moves the "Print Flow" Output of Promax to a predefined Output Path
#! /bin/bash
#
# Define environment
Machine='[Machine Name]'
User='[User Name]'
PromaxData='/Promax/ProMAX/data/[Project Name]/[Line Name]'
OutData="[Output Path]"
# Read number Code of flow. I usually introduce initial numbers for my workflows.
@JesperDramsch
JesperDramsch / markdown_to_bbcode.py
Last active December 22, 2015 18:59 — forked from masukomi/markdown_to_bbcode.py
Included File Operation
import re
def markdown_to_bbcode(s):
links = {}
codes = []
def gather_link(m):
links[m.group(1)]=m.group(2); return ""
def replace_link(m):
return "[url=%s]%s[/url]" % (links[m.group(2) or m.group(1)], m.group(1))
def gather_code(m):
@JesperDramsch
JesperDramsch / SEG-Y EBCDIC Header Extraction
Created September 10, 2013 21:49
This line of code extracts the EBCDIC header of SEG-Y data and makes it human readable in ASCII encoding.
dd bs=3200 count=1 conv=ascii if=data.segy | sed 's/.\{80\}/&\n/g' | sed 's/^.\{3\}/& /g' > header.txt