Skip to content

Instantly share code, notes, and snippets.

View rojaster's full-sized avatar
👁️
I am only the noise on the wires

alekum rojaster

👁️
I am only the noise on the wires
View GitHub Profile
@rojaster
rojaster / gist:526609f10d4a1389b924
Created January 9, 2016 17:26
Change rights on linux system if you failed ones
find . -type d -exec chmod 755 {} +; // for directories recursively
find . -type f -exec chmod 644 {} +; // for files recursively
@rojaster
rojaster / printFilesByExtensionPattern.m
Created June 15, 2016 19:45
function thats prints files by their extension pattern
void printFilesByExtensionPattern(NSString* path, NSString* pattern)
{
NSString *filename;
int index = 0;
for(filename in [[NSFileManager defaultManager] enumeratorAtPath: [path stringByExpandingTildeInPath]])
{
if([[filename pathExtension] isEqualToString: pattern])
{
++index;
NSLog(@"%@ : %d", filename, index);
@rojaster
rojaster / spacemacs-cheatsheet.txt
Created August 21, 2016 14:36 — forked from davoclavo/spacemacs-cheatsheet.md
Spacemacs cheatsheet
`emacs --daemon` to run in the background.
`emacsclient.emacs24 <filename/dirname>` to open in terminal
NOTE: "M-m and SPC can be used interchangeably".
* Undo - `C-/`
* Redo - `C-?`
* Change case: 1. Camel Case : `M-c`
2. Upper Case : `M-u`
3. Lower Case : `M-l`
@rojaster
rojaster / README.md
Created September 6, 2016 19:55 — forked from hofmannsven/README.md
My simply Git Cheatsheet
@rojaster
rojaster / value_decomposition.cpp
Last active December 12, 2018 06:07
Value Decomposition with example
/*
Burning Midnight oil.
Alekum. 2018.
*/
#include <iostream>
#include <iomanip>
#include <stdint.h>
#include <inttypes.h>
#include <bitset>
@rojaster
rojaster / arm_cross_lib_nonsense_remover.sh
Created February 28, 2019 22:47
Delete All Arm Cross Mess Nonse
# similar issue : https://askubuntu.com/questions/1083832/ubuntu-18-04-update-issue?rq=1
sudo apt purge libubsan0-armhf-cross libubsan0-armel-cross libstdc++6-armhf-cross libstdc++6-armel-cross \
libstdc++6-7-dbg-armhf-cross libstdc++-7-dev-armhf-cross libsfubsan0-armhf-cross libsfstdc++6-armhf-cross \
libsfgomp1-armhf-cross libsfcilkrts5-armhf-cross libsfatomic1-armhf-cross libsfasan4-armhf-cross \
libhfubsan0-armel-cross libhfstdc++6-armel-cross libhfgomp1-armel-cross libhfcilkrts5-armel-cross \
libhfatomic1-armel-cross libhfasan4-armel-cross libgomp1-armhf-cross libgomp1-armel-cross libgcc1-armhf-cross \
libgcc1-armel-cross libcilkrts5-armhf-cross libcilkrts5-armel-cross libc6-dev-armel-armhf-cross libc6-armhf-armel-cross \
libc6-armel-armhf-cross libatomic1-armhf-cross libatomic1-armel-cross libasan4-armhf-cross libasan4-armel-cross \
g++-7-arm-linux-gnueabihf g++-7-arm-linux-gnueabihf libasan4-dbg-armhf-cross libatomic1-dbg-armhf-cross \
libcilkrts5-dbg-armhf-cross libgcc-7-dev-armel-cross libgcc-7-dev-a
@rojaster
rojaster / singleton_rules.cpp
Created March 27, 2019 21:45
Display items from the list in two lines. The odds in the first row and evens in the second row. (http://tpcg.io/CXNuxt)
#include <iostream>
#include <list>
#include <vector>
#include <cstdlib>
#include <algorithm>
#include <functional>
// если использовать это то получается херово, потому что будет два вызова
struct prtList
{
@rojaster
rojaster / .spacemacs
Last active February 6, 2022 22:38
.spacemacs
;; -*- mode: emacs-lisp -*-
;; This file is loaded by Spacemacs at startup.
;; It must be stored in your home directory.
(defun dotspacemacs/layers ()
"Configuration Layers declaration.
You should not put any user code in this function besides modifying the variable
values."
(setq-default
;; Base distribution to use. This is a layer contained in the directory
@rojaster
rojaster / androp.py
Created December 19, 2019 01:41
Rooted android phone cpu topology
#!/usr/bin/env python3
#
# MIT License
# alekum(aka rojaster)
# 19/12/2019 ver 0.0.1
#
import os
import sys
from ppadb.client import Client as ADBClient
@rojaster
rojaster / settings.json
Created February 6, 2022 22:37
Visual Studio Code Global Settings JSON
{
"explorer.confirmDragAndDrop": false,
"editor.suggestSelection": "first",
"vsintellicode.modify.editor.suggestSelection": "automaticallyOverrodeDefaultValue",
"editor.fontFamily": "\"Jetbrains Mono ExtraLight\", \"Fira Code\",\"Source Code Pro\", \"Courier New\", monospace",
"editor.fontLigatures": true,
"workbench.colorTheme": "Darktooth",
"editor.fontSize": 15,
"files.exclude": {
"**/.classpath": true,