Skip to content

Instantly share code, notes, and snippets.

View skinzor's full-sized avatar
🎯
Focusing

Robert skinzor

🎯
Focusing
  • Bucharest, Romania
View GitHub Profile
@skinzor
skinzor / README-Template.md
Created August 2, 2018 12:53 — forked from PurpleBooth/README-Template.md
A template to make good README.md

Project Title

One Paragraph of project description goes here

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

@skinzor
skinzor / Camera2.md
Created July 22, 2018 08:13 — forked from Tanapruk/Camera2.md
Camera2 API

TextureView

You need to initialize TextureView before opening a camera. TextureView is for displaying the image from camera on the device. However, you cannot use it unless the texture is ready, either because the screen is currently off or it is initializing.

You should check mTextureView.isAvailable() before opening your camera. Else you will mTextureView.setSurfaceTextureListener(). And open your camera in the callback method onSurfaceTextureListener.

Camera

Before opening your camera you should check for a camera permission first.

#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Created on Mon Feb 19 13:34:45 2018
@author: tomin
"""
import os
import re
@skinzor
skinzor / filter_lineageos_devices.py
Created June 30, 2018 11:32 — forked from ericzolf/filter_lineageos_devices.py
Python script to filter Android devices supported by LineageOS
#!/usr/bin/python
# This crude script allows to filter Android devices supported by LineageOS
# You need to be in the directory where the YAML files are present, which
# are used to create the list seen at https://wiki.lineageos.org/devices/
# You need first to edit the conditions used in the last 'if' statement to
# adapt this script (named $0 below) to your needs. Then usage could look
# like this:
# git clone https://github.com/LineageOS/lineage_wiki.git
# cd lineage_wiki/_data/devices
# (edit $0 and adapt the if-statement at the end of the script)

Install Microsoft Office 2010 on Ubuntu

Requirements

We'll install MSOffice using the PlayOnLinux wizard. Additionally, MSOffice requires samba and winbind to properly work.

So, if not installed, install them:

sudo apt-get install playonlinux samba winbind
@skinzor
skinzor / python_scripting.rst
Created June 14, 2018 16:33 — forked from jasonkeene/python_scripting.rst
Get started with writing your own python scripts to automate system tasks.

Python for System Admins / Operators

Installing Python

Most Unix/Linux systems come with python pre-installed:

$ python -V
@skinzor
skinzor / -
Created June 7, 2018 15:26 — forked from invisiblek/-
/system/bin/linker
__cxa_finalize
__cxa_atexit
_ZTV17ProximityCallback
__aeabi_unwind_cpp_pr0
_ZdlPv
_ZN16MotSpeakerHelper10speakerOffEv
pthread_mutex_lock
pthread_mutex_unlock
_ZN16MotSpeakerHelper12earpiecePingEb
@skinzor
skinzor / dns.txt
Created May 28, 2018 09:48 — forked from CHEF-KOCH/dns.txt
OpenDNS VPN leakage problem
Needs:
- root
- OpenDNS
- OpenDNS as DNs provider
- Tasker (optional) if you want to automatically apply this tweak
1. openvpn –config shopper.ovpn –daemon
2. iptables -t nat -F OUTPUT
3. iptables -t nat -A OUTPUT -p udp –dport 53 -j DNAT –to-desired destination 192.168.1.1
# 192.168.1.1 is the internal IP handle of my router that has DNS server managing and intercepting all packets sent to UDP port fifty three
@skinzor
skinzor / vpn.md
Created May 25, 2018 10:15 — forked from joepie91/vpn.md
Don't use VPN services.

Don't use VPN services.

No, seriously, don't. You're probably reading this because you've asked what VPN service to use, and this is the answer.

Note: The content in this post does not apply to using VPN for their intended purpose; that is, as a virtual private (internal) network. It only applies to using it as a glorified proxy, which is what every third-party "VPN provider" does.

(A Russian translation of this article can be found here, contributed by Timur Demin.)

Why not?

@skinzor
skinzor / Method 1
Created May 21, 2018 12:32 — forked from udacityandroid/Method 1
Android Development for Beginners : Define a Method
private String createCalendarEventReminder(String eventName, String location, int minutesAway) {
String reminder = "You have an upcoming event in " + minutesAway + " minutes.";
reminder = reminder + " It is " + eventName + " held at " + location + ".";
return reminder;
}