Skip to content

Instantly share code, notes, and snippets.

//
// CameraController.swift
//
import AVFoundation
import Photos
import UIKit
class CameraController: UIViewController {
enum Camera {
@zinwalin
zinwalin / git-submodules.md
Created April 13, 2021 10:23 — forked from slavafomin/git-submodules.md
Git submodules best practices

Git submodules best practices

Useful commands

— Clone repository with submodules automatically:

git clone --recursive [email protected]:name/repo.git

— Initialize submodules after regular cloning:

@zinwalin
zinwalin / jetson_nano_commands.md
Last active April 5, 2021 06:34
Regular commands used in daily learning life.

no fuss, no muss...

zsh env setup

sudo apt update -y
sudo apt install zsh -y
chsh -s /bin/zsh
wget https://github.com/robbyrussell/oh-my-zsh/raw/master/tools/install.sh -O - | sh
@zinwalin
zinwalin / iOSDevices
Created February 22, 2021 10:19 — forked from erkanyildiz/iOSDevices
List of iOS devices with names and cpu models
{
"iPhone1,1":
{
"name": "iPhone",
"cpu": "RISC ARM 11"
},
"iPhone1,2":
{
"name": "iPhone 3G",
@zinwalin
zinwalin / ActivityA.java
Created March 3, 2016 07:19
Stackoverflow answer, "Singleton in Android"
package com.example.testSingleton;
import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.widget.Toast;
public class ActivityA extends Activity {
@Override
public void onCreate(Bundle savedInstanceState) {
#Quick cp from http://sekati.com/etc/install-nodejs-on-debian-squeeze
#
#Needed to install TileMill from MapBox
#
#Installs node.js which has npm bundled
#
#Build Dependencies
sudo apt-get update && apt-get install git-core curl build-essential openssl libssl-dev