Skip to content

Instantly share code, notes, and snippets.

View gnubyte's full-sized avatar

gnubyte gnubyte

View GitHub Profile
@gnubyte
gnubyte / DataObject.class.php
Created May 16, 2023 19:42
Basing models off the DataObject Class
<?php
//error_reporting(-1);
//ini_set('display_errors', 'On');
// config.php contents:
//define("DB_DSN", "mysql:dbname=database");
//define("DB_USERNAME", "username");
//define("DB_PASSWORD", "password!");
@gnubyte
gnubyte / copy_remote_files.py
Created August 1, 2018 14:14 — forked from mariusavram91/copy_remote_files.py
Copy remote files to local with Python's Paramiko
import os
import paramiko
paramiko.util.log_to_file('/tmp/paramiko.log')
paramiko.util.load_host_keys(os.path.expanduser('~/.ssh/known_hosts'))
host = 'local'
port = 22
username = 'user'
files = ['file1', 'file2', 'file3', 'file4']