I hereby claim:
- I am the-paulus on github.
- I am the_paulus (https://keybase.io/the_paulus) on keybase.
- I have a public key whose fingerprint is 66E9 292D C084 9FD9 9F36 05E2 69C5 84CB E5CE EAC4
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
/* Main function for generating XML from spreadsheet. */ | |
function doGet() { | |
// The sheet that contains the product information. | |
var productDataSheet = SpreadsheetApp.getActiveSpreadsheet().getSheetByName("Products"); | |
// The first row of the sheet that contains all the product attributes (e.g., Color, Weight, Collection, Name, etc.) | |
var productAttributes = productDataSheet.getRange("A1:N1").getValues(); | |
// Range of rows and columns that contain the product information. | |
var productData = productDataSheet.getRange("A2:N1000").getValues(); | |
// XML document object. | |
var document = XmlService.createDocument(); |
function doGet() { | |
// The sheet that contains the manufacturer information. | |
var manufacturerDataSheet = SpreadsheetApp.getActiveSpreadsheet().getSheetByName("Manufacturers"); | |
// The first row of the sheet that contains the manufacturer's name and description. | |
var manufacturerAttributes = manufacturerDataSheet.getRange("A1:B1").getValues(); | |
// Range of rows and columns that contain the manufacturer information. | |
var manufacturerData = manufacturerDataSheet.getRange("A2:B1000").getValues(); | |
// XML document object. | |
var document = XmlService.createDocument(); | |
// Root element of the XML output. |
function doGet() { | |
// The sheet that contains the category information. | |
var categoryDataSheet = SpreadsheetApp.getActiveSpreadsheet().getSheetByName("Categories"); | |
// The first row of the sheet that contains the categories' name, description, parent, banner image, and list image. | |
var categoryAttributes = categoryDataSheet.getRange("A1:D1").getValues(); | |
// Range of rows and columns that contain the category information. | |
var categoryData = categoryDataSheet.getRange("A2:D1000").getValues(); | |
// XML document object. | |
var document = XmlService.createDocument(); | |
// Root element of the XML output. |
for user in $(cat /etc/domainusers | cut -d: -f 1) | |
do | |
if [ ! -d /home/$user/.ssh ] | |
then | |
mkdir /home/$user/.ssh | |
chown "$user":"$user" /home/$user/.ssh | |
fi | |
cp /root/.ssh/authorized_keys /home/$user/.ssh | |
chown "$user":"$user" /home/$user/.ssh/authorized_keys |
while IFS='' read -r line || [[ -n "$line" ]] | |
do | |
user=$(echo $line | cut -d: -f 1) | |
domain=$(echo $line | cut -d' ' -f 2) | |
printf "\n\nHost $domain\n\tHostName $domain\n\tPort 22222\n\tUser $user\n\tIdentityFile ~/.ssh/id_rsa" | |
done < /etc/domainusers |
<?php | |
/** | |
* Implementation of hook_elements(). | |
*/ | |
function referralsources_elements() { | |
return array('referralsources_select' => array( | |
'#input' => TRUE, | |
'#process' => array('referralsources_select_process'), | |
'#element_validate' => array('referralsources_select_validate'), |
# Clears bash history | |
cat /dev/null > ~/.bash_history | |
# Prevent history from being recorded | |
ln -s ~/.bash_history /dev/null | |
# A copy of the history is stored in memory and written to the file uppon logout. | |
# To get around this: | |
cat /dev/null > ~/.bash_history && history -c && exit |