Skip to content

Instantly share code, notes, and snippets.

View kolosovsky's full-sized avatar

Eduard Kolosovskyi kolosovsky

  • Box Poland
  • Poland
View GitHub Profile
repositories=( 'path/to/repo1' 'path/to/repo2' 'path/to/repo2' )
for i in "${repositories[@]}"
do
cd $i;
if [ -z "$(git status --porcelain)" ]; then
echo "repo is clean: $i";
else
git add . && git commit -m 'message';
fi
@kolosovsky
kolosovsky / transformation-matrix.md
Last active May 20, 2018 10:39
Transformation matrix in JavaScript
@kolosovsky
kolosovsky / aabb.md
Last active February 3, 2024 14:16
The computation of the axis-aligned bounding box (AABB) in JavaScript

The computation of the axis-aligned bounding box (AABB) in JavaScript

Polygon (rectangle, triangle, etc.)

Live demo https://jsfiddle.net/Kolosovsky/tdqv6pk2/

let points = [
	{ x: 125, y: 50 },
	{ x: 250, y: 65 },
@kolosovsky
kolosovsky / sorting.md
Last active May 17, 2018 13:52
Sorting algorithms in JavaScript

Sorting algorithms in JavaScript

var i = -1,
	arr1 = [],
	arr2 = [],
	arr3 = [],
	arr4 = [],
	randomNumber;