This file contains hidden or 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
################################################################################ | |
# FILE ARCHIVING SCRIPT # | |
#*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*&&*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*# | |
# AUTHOR: Tim Caldwell DATE: 22/02/2013 # | |
# DESCRIPTION: # | |
# This script takes your command-line input for the root source and dest. # | |
# folders and will copy (archive) any files older than the $days specified # | |
################################################################################ | |
################################################################################ |
This file contains hidden or 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
<# | |
.SYNOPSIS | |
Creates new users via PIPS K2 | |
.DESCRIPTION | |
This script takes input from variables given to it by K2 and creates | |
a new user to Lion spec | |
.PARAMETER <paramName> | |
$firstName - First name of the New Starter | |
$lastName - Last name of the New Starter | |
$middleName - Middle Name of the New Starter |
This file contains hidden or 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
<############################################################################### | |
Import-ADSites | |
################################################################################ | |
DEPENDENCIES: Powershell Module - ActiveDirectory | |
SQL Access to referenced SQL server and Database | |
DESCRIPTION: Adds new AD Sites to LANSweeper and schedules a scan of | |
their IP subnets. | |
CHANGE LOG: |
This file contains hidden or 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
#"Running" | Out-File "C:\Temp\Service.log" -append | |
Do { | |
#"Start Of Loop" | Out-File "C:\Temp\Service.log" -append | |
$Adaptors = Get-WmiObject -query "SELECT * FROM Win32_NetworkAdapter WHERE PhysicalAdapter = 1 AND NOT Description LIKE '%Virtual%' AND (NetConnectionID LIKE '%Wireless Network Connection%' OR NetConnectionID LIKE '%Local Area Connection%' OR NetConnectionID LIKE '%Wi-Fi%' OR NetConnectionID LIKE '%Ethernet%')" | |
$NetEnabledAdaptors = @($Adaptors | Where {$_.NetEnabled -eq $true}).Count | |
#"Adaptors Found: $($Adaptors.Count)" | Out-File "C:\Temp\Service.log" -append | |
#"Net Enabled Adaptors: $NetEnabledAdaptors" | Out-File "C:\Temp\Service.log" -append | |
if ($NetEnabledAdaptors -gt 1) | |
{ | |
#"WiFi and LAN Connected. Disabling WiFi..." | Out-File "C:\Temp\Service.log" -append |
This file contains hidden or 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
################################################################################ | |
# AD PROFILE PICTURE EXTRACTOR # | |
################################################################################ | |
# THIS SCRIPT WILL GET THE thumbnailPhoto ATTRIBUTE FROM ACTIVE DIRECTORY USER # | |
# AND SAVE TO JPEG # | |
# # | |
# AUTHOR: TIM CALDWELL # | |
# DATE: 21/02/2014 # | |
################################################################################ | |
param( |
This file contains hidden or 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
//create empty array of bank accounts | |
let bankAccounts = [] | |
// function to create a new account | |
const addAccount = function( name, amount ) { | |
// create new account object | |
let newAccount = { | |
accountName: name, | |
balance: amount |
This file contains hidden or 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
// sum shopping cart items js | |
// shopping cart object | |
const cartForParty = { | |
banana: "1.25", | |
handkerchief: ".99", | |
Tshirt: "25.01", | |
apple: "0.60", | |
nalgene: "10.34", | |
proteinShake: "22.36" |
This file contains hidden or 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
################################################################################ | |
# GLaDOS SHELL Welcome Messages! | |
################################################################################ | |
# Colours Variables | |
RESET="\033[0m" | |
BOLD="\033[1m\e[38;5;214m" | |
ORANGE="\e[38;5;208m" | |
# FUN GLaDOS QUOTES!!! | |
echo "${BOLD}Initialising GLaDOS...${RESET}" |
This file contains hidden or 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
$(document).ready(function() { | |
const balance = { | |
savings: 0, | |
checking: 0 | |
}; | |
//CHANGING COLOR ON $0... | |
const zeroBalance = function() { | |
if (balance['savings'] === 0) { |
This file contains hidden or 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
// <input type="range" id="size" min="3" max="10" value="3"> | |
// <div class="board"> | |
// </div> | |
let p = 0; | |
const s = []; | |
let size = +$('#size').val() //set size to default | |
const makeBoard = function() { | |
size = +$('#size').val() //get size from input |
OlderNewer