Skip to content

Instantly share code, notes, and snippets.

View gioxx's full-sized avatar
☮️
I do things, I see people, I write.

Giovanni Francesco Solone gioxx

☮️
I do things, I see people, I write.
View GitHub Profile
@gioxx
gioxx / mirror_remote_directory_to_local_directory
Last active January 26, 2022 13:48 — forked from pixeline/mirror_remote_directory_to_local_directory
Bash script using lftp to mirror remote directory to local directory, thus keeping the local directory synchronized with the remote one.
#!/bin/sh
# @author: Alexandre Plennevaux
# @description: MIRROR DISTANT FOLDER TO LOCAL FOLDER VIA FTP
HOST='sftp://ftp.domain.com'
USER='ftpusername'
PASSWORD='ftppassword'
REMOTE_DIR='/absolute/path/to/remote/directory'
LOCAL_DIR='/absolute/path/to/local/directory'
@gioxx
gioxx / index.php
Created May 13, 2019 13:35 — forked from flodolo/index.php
Install local XML files
<?php
$full_url = "//{$_SERVER['HTTP_HOST']}{$_SERVER['REQUEST_URI']}";
?>
<!DOCTYPE html>
<html>
<head>
<meta charset=utf-8>
<title>Install searchplugins</title>
<script type="text/javascript">
function installSearchPlugin(pluginname) {
@gioxx
gioxx / arch_wmi_conn_getdwordvalue.vbs
Created May 14, 2018 09:08 — forked from MyITGuy/arch_wmi_conn_getdwordvalue.vbs
A WMI registry call through VBScript using the StdRegProv class with no architecture specified (GetStringValue)
Const HKEY_LOCAL_MACHINE = &H80000002, HKLM = &H80000002
WScript.Echo GetDWordValue (".", HKEY_LOCAL_MACHINE, "SOFTWARE\Altiris\Client Service", "UserInfoInterval", 32)
WScript.Echo GetDWordValue (".", HKEY_LOCAL_MACHINE, "SOFTWARE\Altiris\Client Service", "UserInfoInterval", 64)
Function GetDWordValue (ByVal Resource, ByVal hDefKey, ByVal SubKeyName, ByVal ValueName, ByVal Architecture)
Const wbemAuthenticationLevelPktPrivacy = 6
Const wbemImpersonationLevelImpersonate = 3
Dim oCtx: Set oCtx = CreateObject("WbemScripting.SWbemNamedValueSet")
oCtx.Add "__ProviderArchitecture", Architecture