Skip to content

Instantly share code, notes, and snippets.

View protorob's full-sized avatar

protorob

View GitHub Profile
#!/bin/bash -e
# Start allways the same
wpuser='yourusername'
wpuseremail='yourname@yourdomain.tld'
wpuserpass=$(date +%s | sha256sum | base64 | head -c 10)
dpprefix=$(date +%s | sha256sum | base64 | head -c 6)
clear
<?php
$json = file_get_contents( dirname(__FILE__) . DIRECTORY_SEPARATOR . "prdmd.json");
$jsonToArray = json_decode($json, true);
$productTemplate =
'Title:
{{title}}
----
Identifier:
@protorob
protorob / artowoo.sh
Last active May 4, 2024 11:52
Bash Sript to Automate the Configuration of the Artomultiplo's Woocommerce Starter Kit
#!/bin/bash -e
# Start allways the same
wpuser='yourusername'
wpuseremail='yourname@yourdomain.tld'
wpuserpass=$(date +%s | sha256sum | base64 | head -c 16)
dpprefix=$(date +%s | sha256sum | base64 | head -c 6)
clear
@protorob
protorob / artomultiplo-backups.sh
Created April 12, 2017 08:28
A rude way to create tarballs of your server files and then cancelling it
#!/bin/bash -e
#Giving a name to the file
echo "Name your file (Without .tar.gz - avoid dots and special characters): "
read -e filename
#Making a tar file with the directory excluding snapshot folder
env GZIP=-9 tar cvzf "$filename".tar.gz mywebsite.com/ --exclude="mywebsite.com/wp-content/uploads/snapshots"
#Moving the file to a public directory
<div class="cf7-custom-style">
<div class="grid-50">
[text* your-name placeholder "Name"]
</div>
<div class="grid-50">
[email* your-email placeholder "Email"]</div>
<div class="grid-100">
[text your-subject placeholder "Subject"]
</div>
<div class="grid-100">