Skip to content

Instantly share code, notes, and snippets.

View abelhegedus's full-sized avatar

Ábel Hegedüs abelhegedus

View GitHub Profile
@m-radzikowski
m-radzikowski / script-template.sh
Last active August 18, 2024 12:49
Minimal safe Bash script template - see the article with full description: https://betterdev.blog/minimal-safe-bash-script-template/
#!/usr/bin/env bash
set -Eeuo pipefail
trap cleanup SIGINT SIGTERM ERR EXIT
script_dir=$(cd "$(dirname "${BASH_SOURCE[0]}")" &>/dev/null && pwd -P)
usage() {
cat <<EOF
Usage: $(basename "${BASH_SOURCE[0]}") [-h] [-v] [-f] -p param_value arg1 [arg2...]
@hwellmann
hwellmann / pom-snippet.xml
Last active May 14, 2024 13:13
Integrating EMF code generation from an Ecore model into a Tycho build. Sources: my.ecore, my.genmodel, plugin.xml, META-INF/MANIFEST.MF. build.properties Generated Java sources end up in target/generated-sources/emf/src. This directory is included in build.properties as an additional source folder.
<plugin>
<groupId>org.eclipse.tycho.extras</groupId>
<artifactId>tycho-eclipserun-plugin</artifactId>
<!-- tested with 0.18 -->
<version>${tycho.version}</version>
<configuration>
<!-- linebreaks not permitted in this arg line -->
<appArgLine>-data target/workspace -application org.eclipse.emf.codegen.ecore.Generator -projects ${basedir} -model ${basedir}/model/my.genmodel target/generated-sources/emf</appArgLine>
<dependencies>
<dependency>