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
// Put this file in Program Files\Adobe\Photoshop\Presets\Scripts\ | |
// In PhotoShop menu File > Automate > Scripts: layersToSprite.js | |
// Arrange layers into a sprite sheet. | |
if (documents.length > 0) | |
{ | |
// -------------------------- | |
docRef = activeDocument; |
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
<?php | |
exec('mysqldump --user=dbuser --password=dbpass --host=127.0.0.1 dbuser > /root/mysql_backups/'.date("d-m-Y").'.sql'); | |
$conn_id = ftp_connect("lepus.ip"); | |
$login_result = ftp_login($conn_id, "storage", "password"); | |
if (ftp_put($conn_id, date("d-m-Y").".sql", "/root/mysql_backups/".date("d-m-Y").".sql", FTP_ASCII)) | |
{ |
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
<?php | |
// In addition to explanations from: | |
// https://stackoverflow.com/questions/53773313/how-to-get-generate-aws-quicksight-secure-dashboard-url/54052069#54052069 | |
use Aws\Sts\StsClient; | |
use Aws\Credentials\Credentials; | |
use Aws\QuickSight\QuickSightClient; | |
use Aws\CognitoIdentity\CognitoIdentityClient; | |
use Aws\QuickSight\Exception\QuickSightException; |