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
if $CmdLine[0] >= 1 Then | |
$userInput = $CmdLine[1] | |
Else | |
$userInput = InputBox("GetURL", "Enter the bame of the browser", "firefox", "", "") | |
EndIf | |
if $userInput == "firefox" Then | |
$window = "[CLASS:MozillaWindowClass]" | |
if not winexists($window)=1 then; | |
MsgBox(0, "GetURL", "Mozilla Firefox is not running") |
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
@echo off | |
:loop | |
REM Check if the process is already running | |
tasklist /fi "imagename eq %1" | find /i "%1" > nil | |
if errorlevel 1 ( | |
REM If not start the process | |
goto :main | |
) else ( | |
REM Else keep checking every 5 seconds whether it is alive |
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
require 'net/http' | |
require 'net/https' | |
require 'uri' | |
require 'pry' | |
class Proxy | |
def server(port) | |
puts "Starting Proxy server on port #{port}" | |
@socket = TCPServer.new('localhost', port) | |
loop do |
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 | |
set -e | |
############################################### | |
### Add this to your ~/.ssh/config # | |
### ControlPath ~/.ssh/master-%r@%h:%p # | |
### ControlMaster no # | |
### Run this as ./persistent_ssh.sh box1 box2 # | |
############################################### | |
MY_PROMPT="$ " |
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
### Admin email address | |
[email protected] | |
### Setup the server to mirror | |
mirror=rsync://archive.ubuntu.com/ubuntu | |
### Log file path | |
log=/var/log/ubuntu | |
### Setup the local directory |
NewerOlder