Skip to content

Instantly share code, notes, and snippets.

@mgoellnitz
mgoellnitz / wipe-unused-cm-references.sh
Last active March 8, 2026 17:16
In CoreMedia Blueprint Workspaces locally remove most ancient tags
#!/bin/sh
#
# Wipe most likely unused references from CoreMedia repositories
# before pushing them to our custom repositories.
#
for r in $(git remote) ; do
if [ "$(git remote get-url $r|grep coremedia-contributions|wc -l)" != "0" ] ; then
COREMEDIA=$r
fi
done
@mgoellnitz
mgoellnitz / pdf-remove-page.sh
Last active March 8, 2026 17:18
Remove one page from a PDF file - defaults to last one
#!/bin/sh
#
# Copyright 2021-2026 Martin Goellnitz
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
@mgoellnitz
mgoellnitz / check-actions.sh
Last active March 8, 2026 17:24
Find GitHub/Forgejo/Gitea actions files and check for latest versions
#!/bin/sh
#
# Copyright 2023-2026 Martin Goellnitz
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
@mgoellnitz
mgoellnitz / find-non-coremedia-changes.sh
Last active October 8, 2025 18:39
Find any non-CoreMedia-originating changes in your workspace
#!/bin/sh
#
# Find any changes in your workspace, which do not stem from the original
# CoreMedia internal sources. Optionally compare with CoreMedia or other
# git reference if there are any false positives from merges.
#
# Must be called from within workspace.
#
# Copyright 2018-2025 Martin Goellnitz
#
@mgoellnitz
mgoellnitz / pdf-compress.sh
Last active March 8, 2026 17:18
Reduce PDF File Size to still readable and printable State
#!/bin/sh
#
# Copyright 2021-2026 Martin Goellnitz
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
@mgoellnitz
mgoellnitz / beangenerator.sh
Last active March 31, 2025 13:42
CoreMedia Bean Generator in one Line - multi-version and workspace aware
#!/bin/bash
#
# Call the CoreMedia CAE Bean Generator for any CMS Release, with
# or without workspace context and without separate preparation steps.
#
# Copyright 2017-2025 Martin Goellnitz
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
@mgoellnitz
mgoellnitz / clean-old-gitlab-pipelines.sh
Last active March 28, 2026 10:46
Clean old GitLab CI build job's results
#!/bin/bash
#
# Copyright 2017-2026 Martin Goellnitz
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
@mgoellnitz
mgoellnitz / snip.sh
Last active April 9, 2026 22:16
GitLab Snippet Command Line Tool
#!/bin/sh
#
# Copyright 2016-2025 Martin Goellnitz
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
@mgoellnitz
mgoellnitz / gist.sh
Last active March 28, 2026 12:28
Gist Command Line Tool for Single File Gists
#!/bin/sh
#
# Copyright 2016-2026 Martin Goellnitz
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
@mgoellnitz
mgoellnitz / git-recover.sh
Last active April 12, 2026 22:58
GIT recovery support script to easily set some defaults when (re-)cloning a set of repositories
#!/bin/bash
#
# (Re-)Clone git repositories with some essential parameters set alongside
# following a small configuration descriptory file mentioning author name
# and email, remotes, push mode, local standard branch, branch tracking-relation
# setup.
#
# Copyright 2016-2026 Martin Goellnitz
#
# This program is free software: you can redistribute it and/or modify