Skip to content

Instantly share code, notes, and snippets.

@markasoftware
markasoftware / enterprise_token.rb
Last active May 7, 2024 06:36
OpenProject Enterprise mode for free
############ REPLACE app/models/enterprise_token.rb in the source code with this file! ################
############ also be sure to RESTART OpenProject after replacing the file. ################
############ it doesn't show that enterprise mode is enabled in the settings, but all ################
############ enterprise mode features, such as KanBan boards, are enabled. ################
#-- copyright
# OpenProject is an open source project management software.
# Copyright (C) 2012-2023 the OpenProject GmbH
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License version 3.
@YakDriver
YakDriver / shell_try_catch.sh
Created February 14, 2018 15:27
Bash Basics: A Robust try/catch/finally for shell scripts
#!/bin/bash
# This script uses traps to create try/catch/finally functionality in shell scripts.
#
# OUTPUT:
#
# Hello! We're reporting live from script
# ./try_catch2.sh: line 23: badcommand: command not found
# ./try_catch2.sh: line 23: exiting with status 127
# It's the end of the line
@alexellis
alexellis / k8s-pi.md
Last active April 11, 2024 14:17
K8s on Raspbian
<alignment jcr:primaryType="nt:unstructured"
name="./alignChildren"
fieldLabel="Alignment of components"
required="{Boolean}true"
selectionMode="single"
sling:resourceType="granite/ui/components/coral/foundation/form/buttongroup">
<items jcr:primaryType="nt:unstructured">
<default jcr:primaryType="nt:unstructured"
name="./default"
@babhishek21
babhishek21 / range_sum_query_mutable_leetcode.cpp
Last active May 23, 2023 16:21
Range Sum Query for Mutable Arrays using Segment Trees
#include <bits/stdc++.h> // using GCC/G++11
using namespace std;
/**
* Range Sum Query for Mutable Arrays using Segment Trees (LeetCode)
* https://leetcode.com/problems/range-sum-query-mutable/
*
* Build a tree whose nodes represent the entire range. Its two children represent the two halves
* of this range. This continues down the tree with height log(n) until we reach the n individual
* leaves of the tree (each representing a single element).
@hackerdem
hackerdem / check_link.py
Last active January 5, 2023 18:22
A simple python script to check broken links of a wesite
@bastelflp
bastelflp / .gitconfig
Last active February 1, 2023 09:49 — forked from shawndumas/.gitconfig
Using WinMerge as the git Diff/Merge Tool and Notepad++ for commit messages on Windows 64bit
[mergetool]
prompt = false
keepBackup = false
keepTemporaries = false
[merge]
tool = winmerge
[mergetool "winmerge"]
name = WinMerge