-
Install Termux, an Android terminal emulator that provides a Linux execution environment and various tools.
-
Update system packages in Termux:
$ pkg update -y
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
using UnityEngine.AddressableAssets; | |
using UnityEngine.AddressableAssets.ResourceLocators; | |
using UnityEngine.ResourceManagement; | |
using UnityEngine.ResourceManagement.ResourceLocations; | |
using UnityEngine.ResourceManagement.ResourceProviders; | |
using UnityEngine.ResourceManagement.AsyncOperations; | |
using UnityEngine.SceneManagement; | |
using System.Collections; | |
using System.Collections.Generic; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
date_string=`date +%F-%s` | |
# Creates Screenrecords directory if not exist. | |
mkdir -p Screenrecords | |
function finish() { | |
adb shell pkill -SIGINT screenrecord | |
adb pull /sdcard/screenrecord_"$date_string".mp4 ./Screenrecords/ | |
adb shell rm /sdcard/screenrecord_"$date_string".mp4 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const fs = require("fs"); | |
/** | |
* Removes matching outer quotes from a string. | |
* | |
* @param {string} text - String to unquote | |
* @returns {string} - Unquoted string | |
*/ | |
const unquote = text => /(["'])?(.*)\1/.exec(text)[2]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.IO; | |
using UnityEditor.PackageManager; | |
using UnityEngine; | |
namespace UnityEditor.Extensions | |
{ | |
#if UNITY_2017_3_OR_NEWER | |
/// <summary> | |
/// Editor extension for embedding packages as a local copy in the project. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
using System; | |
/// <summary> | |
/// Temporarily set a color to be used for Gizmos. | |
/// <example> | |
/// <code> | |
/// using (new GizmosColor(Color.red)) | |
/// { |
First, install it, using apt, yum, pacman, etc.
Imagine we want to back up files from Directory1 to Directory2, and both are on the same hard drive (this would work the same if the directories are on two different drives). There are several different ways to do this, depending on what kind of backups (i.e., options you want to give rsync) you want to configure. The most general, will be this:
$ rsync -av --delete /Directory1/ /Directory2/
alias status="artii 'Status' | nyan && git status | nyan"
alias add="git add . | artii "Staged" | nyan"
alias glocal="git checkout local | artii 'Local Branch' | nyan"
alias dev="git checkout dev | artii 'Dev Branch' | nyan"
alias master="git checkout master | artii 'Master Branch' | nyan"
alias log="artii 'Logs' | nyan && git log | nyan"
alias branch="artii 'Branches' | nyan && git branch | nyan"
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@mixin supports($property-dec) { | |
// find position of colon in property declaration | |
$colon: str-index($property-dec, ':'); | |
// extract the property | |
$property: str-slice($property-dec, 1, $colon - 1); | |
// extract the value | |
$value: str-slice($property-dec, $colon + 1); | |
// trim leading spaces | |
@while (str-slice($value, 1, 1) == ' ') { | |
$value: str-slice($value, 2); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/******************************************************************************* | |
* Don't Be a Jerk: The Open Source Software License. | |
* Adapted from: https://github.com/evantahler/Dont-be-a-Jerk | |
******************************************************************************* | |
* _I_ am the software author - JohannesMP on Github. | |
* _You_ are the user of this software. You might be a _we_, and that's OK! | |
* | |
* This is free, open source software. I will never charge you to use, | |
* license, or obtain this software. Doing so would make me a jerk. | |
* |
NewerOlder