Skip to content

Instantly share code, notes, and snippets.

@Nadav-Ruskin
Nadav-Ruskin / godot navigation region from collision shape.gd
Last active March 31, 2024 19:50
Create a navigation region for a NavigationRegion2D from a NavigationRegion2D
extends Node2D
@onready var collision_shape_2d: CollisionShape2D = $Area2D/CollisionShape2D
@onready var navigation_region_2d: NavigationRegion2D = $NavigationRegion2D
func _ready() -> void:
"""
When object is ready, bake a navigation mesh from its collision shape.
"""
var rect: Rect2 = collision_shape_2d.shape.get_rect()
@Nadav-Ruskin
Nadav-Ruskin / trace3.txt
Created July 22, 2018 09:40
Parallel make fails. make -j<any number above 1>
This file has been truncated, but you can view the full file.
381 execve("/usr/bin/make", ["make", "-j9"], [/* 25 vars */]) = 0
381 brk(0) = 0x2219000
381 access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
381 mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fab6fdd6000
381 access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
381 open("/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
381 fstat(3, {st_mode=S_IFREG|0644, st_size=24180, ...}) = 0
381 mmap(NULL, 24180, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7fab6fdd0000
381 close(3) = 0
381 access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
@Nadav-Ruskin
Nadav-Ruskin / trace2.txt
Created July 17, 2018 12:25
Parallel make fails. make -j<any number above 1>
This file has been truncated, but you can view the full file.
1519 execve("./linux-armv7", ["./linux-armv7", "-a", "-v/.ccache:/.ccache", "bash", "-c", "cd build && cmake -DCMAKE_MAKE_P"...], 0x7fffc05c4580 /* 22 vars */) = 0
1519 brk(NULL) = 0x7fffd9c6c000
1519 access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
1519 access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
1519 openat(AT_FDCWD, "/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
1519 fstat(3, {st_mode=S_IFREG|0644, st_size=95301, ...}) = 0
1519 mmap(NULL, 95301, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7fb673dbe000
1519 close(3) = 0
1519 access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
1519 openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libtinfo.so.5", O_RDONLY|O_CLOEXEC) = 3
@Nadav-Ruskin
Nadav-Ruskin / trace.txt
Created July 17, 2018 09:04
Parallel make fails. make -j<any number above 1>
execve("./linux-armv7", ["./linux-armv7", "-a", "-v/.ccache:/.ccache", "bash", "-c", "cd build && cmake -DCMAKE_MAKE_P"...], 0x7fffc915cf58 /* 22 vars */) = 0
brk(NULL) = 0x7fffd7f36000
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=95301, ...}) = 0
mmap(NULL, 95301, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f3cf9055000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libtinfo.so.5", O_RDONLY|O_CLOEXEC) = 3
@Nadav-Ruskin
Nadav-Ruskin / yourapp
Created June 17, 2018 11:31 — forked from leplatrem/yourapp
gunicorn virtualenv init.d script (could be simpler with upstart)
#! /bin/bash
### BEGIN INIT INFO
# Provides: yourapp
# Required-Start: nginx
# Required-Stop:
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: The main django process
# Description: The gunicorn process that receives HTTP requests
# from nginx
@Nadav-Ruskin
Nadav-Ruskin / answer.md
Last active March 30, 2018 09:35
Answer for tomoaki0705

Hello again @tomoaki0705 , thank you very much for your continued assistance.

compiler

[osboxes:/opencv/opencv] $ aarch64-linux-gnu-g++ cmake/checks/cpu_neon.cpp
In file included from cmake/checks/cpu_neon.cpp:8:0:
/usr/lib/gcc/aarch64-linux-gnu/4.9/include/arm_neon.h: In function 'uint8x8_t vqadd_u8(uint8x8_t, uint8x8_t)':
/usr/lib/gcc/aarch64-linux-gnu/4.9/include/arm_neon.h:2116:51: error: '__builtin_aarch64_uqaddv8qi_uuu' was not declared in this scope
   return __builtin_aarch64_uqaddv8qi_uuu (__a, __b);

... similar errors

@Nadav-Ruskin
Nadav-Ruskin / jenkins-git-backup.sh
Created October 30, 2017 08:01 — forked from abayer/jenkins-git-backup.sh
Example of a script for backing up Jenkins config in git.
# This script assumes you have a repository that contains a directory called jenkins_home.
# It goes to a specified backup workspace, checks the repository from github, copies only wanted files from jenkins_home,
# copies all files in the repository's root (probably scripts), commits only existing files, pushes the changes, and removes the backup directory.
# Set this script up to run automatically as follows:
# sudo crontab -e
# 29 0 * * * ">>insert the script's location, perferrably it's inside REPOSITORY_HOME<<"
set -ex
git config --global user.name ">>insert bot's user name<<"
git config --global user.email ">>insert bot's email in quotation marks<<"