Skip to content

Instantly share code, notes, and snippets.

View ilg-ul's full-sized avatar

Liviu Ionescu ilg-ul

View GitHub Profile
@ilg-ul
ilg-ul / gnuarmeclipse-c-cpp-formatter-style.xml
Created October 19, 2015 11:52
GNU ARM Eclipse C/C++ formatter style
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<profiles version="1">
<profile kind="CodeFormatterProfile" name="GNU with spaces" version="1">
<setting id="org.eclipse.cdt.core.formatter.insert_space_after_opening_paren_in_exception_specification" value="do not insert"/>
<setting id="org.eclipse.cdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression" value="do not insert"/>
<setting id="org.eclipse.cdt.core.formatter.insert_space_before_closing_paren_in_for" value="do not insert"/>
<setting id="org.eclipse.cdt.core.formatter.insert_space_before_closing_brace_in_array_initializer" value="insert"/>
<setting id="org.eclipse.cdt.core.formatter.insert_space_before_opening_paren_in_for" value="insert"/>
<setting id="org.eclipse.cdt.core.formatter.indent_statements_compare_to_body" value="true"/>
<setting id="org.eclipse.cdt.core.formatter.insert_space_after_colon_in_base_clause" value="insert"/>
@ilg-ul
ilg-ul / .gitignore
Last active November 4, 2016 09:29
Install MacPorts (DEPRECATED)
.vscode
@ilg-ul
ilg-ul / install-homebrew.sh
Last active November 5, 2016 10:11
Install Homebrew in /opt/homebrew.
#!/usr/bin/env bash
if [[ ${DEBUG} != "" ]]; then
set -x
fi
set -o errexit
set -o pipefail
set -o nounset
@ilg-ul
ilg-ul / install-macports-from-sources.sh
Last active November 5, 2016 10:12
Install MacPorts in /opt/macports from sources.
#!/usr/bin/env bash
if [[ ${DEBUG} != "" ]]; then
set -x
fi
set -o errexit
set -o pipefail
set -o nounset
@ilg-ul
ilg-ul / .gitignore
Last active January 2, 2017 08:09
Install local build tools in $HOME/opt/ (multiple Homebrew instances and TeX)
vscode.mac.command
@ilg-ul
ilg-ul / bintray-test.sh
Created March 10, 2017 14:27
Bintray test script to upload Eclipse p2 repositories
#!/usr/bin/env bash
# -----------------------------------------------------------------------------
# Safety settings (see https://gist.github.com/ilg-ul/383869cbb01f61a51c4d).
if [[ ! -z ${DEBUG} ]]
then
set -x # Activate the expand mode if DEBUG is anything but empty.
fi
@ilg-ul
ilg-ul / script-cwd.sh
Last active September 10, 2017 20:32
Sequence to set the current folder.
# Include this part after the bash-init.sh part
script_path="$0"
if [[ "${script_path}" != /* ]]
then
# Make relative path absolute.
script_path="$(pwd)/$0"
fi
@ilg-ul
ilg-ul / generic.mac.command
Last active September 10, 2017 20:35
macOS Finder command that calls the peer name.sh script from the same folder
#!/usr/bin/env bash
# -----------------------------------------------------------------------------
# Safety settings (see https://gist.github.com/ilg-ul/383869cbb01f61a51c4d).
if [[ ! -z ${DEBUG} ]]
then
set -x # Activate the expand mode if DEBUG is anything but empty.
fi
@ilg-ul
ilg-ul / bash-inits.sh
Last active April 19, 2022 13:24
BASH recommended initialisation sequence
#!/usr/bin/env bash
# -----------------------------------------------------------------------------
# Safety settings (see https://gist.github.com/ilg-ul/383869cbb01f61a51c4d).
if [[ ! -z ${DEBUG} ]]
then
set ${DEBUG} # Activate the expand mode if DEBUG is anything but empty.
else
DEBUG=""
@ilg-ul
ilg-ul / license-mit-c-header-micro-os-plus.txt
Last active July 7, 2022 17:09
MIT license for the µOS++ project.
/*
* This file is part of the µOS++ distribution.
* (https://github.com/micro-os-plus)
* Copyright (c) 2022 Liviu Ionescu. All rights reserved.
*
* Permission is hereby granted, free of charge, to any person
* obtaining a copy of this software and associated documentation
* files (the "Software"), to deal in the Software without
* restriction, including without limitation the rights to use,
* copy, modify, merge, publish, distribute, sublicense, and/or