Skip to content

Instantly share code, notes, and snippets.

@flycarl
flycarl / gist:2465163
Created April 22, 2012 16:37 — forked from svetlyak40wt/gist:15067
Simple script, to install refactoring plugin for Vim
#!/bin/bash
# Plant rope vim's plugin
# This is a script to install or update 'ropevim'
# Copyright Alexander Artemenko, 2008
# Contact me at svetlyak.40wt at gmail com
function create_dirs
{
mkdir -p src
@flycarl
flycarl / MakeCoinCurve.cs
Created February 24, 2017 07:59
Unity Editor Script to Generate Objects in a curve
using System.IO;
using UnityEngine;
using UnityEditor;
using System.Collections.Generic;
public class MakeCoinCurve : EditorWindow {
private Vector3 m_startPos;
private float m_forwardSpeed = 6f;
private float m_upSpeed = 13.5f;
@flycarl
flycarl / MakeItemsLine.cs
Created February 24, 2017 08:01
Unity Editor Script to make items in line
using System.IO;
using UnityEngine;
using UnityEditor;
using System.Collections.Generic;
public class MakeItemsLine : EditorWindow
{
private Vector3 m_startPos;
private float m_unitLength;
@flycarl
flycarl / ReplacePrefab.cs
Created February 24, 2017 08:06
Unity Editor Script, put a prefab in editor window, select a transform in Hierarchy, then click Replace button, the tranform will replace with the prefab.
using UnityEngine;
using UnityEditor;
public class ReplacePrefab : EditorWindow {
[MenuItem("GameEditor/ReplacePrefab")]
public static void ShowWindow()
{
EditorWindow.GetWindow(typeof(ReplacePrefab));
}
@flycarl
flycarl / cloab-ssh.sh
Last active November 9, 2024 13:15
This is a Bash script designed to set up a secure SSH connection to a Colab notebook using ngrok
#!/bin/bash
# Function to print error messages
error() {
echo "ERROR: $1" >&2
exit 1
}
# Function to print usage
usage() {