Rclone Automount

This assumes that rclone is already downloaded and stored in the following directory:

C:\Tools\rclone-v1.71.2-windows-amd64

  1. Create a VBS script from the following template and edit it to your needs:

    'Rclone Automount Script Template
    'by OperaVaria, 2024.
    
    'Mandatory variable declaration, helps to avoid errors.
    Option Explicit
    
    'Declare cmd variables:
    Dim cmd1, cmd2, cmd3 'Arbitrary number of three commands in template, add or remove according to your needs.
    
    'Assign rclone commands to cmd variables:
    cmd1 = "C:\Tools\rclone-v1.71.2-windows-amd64\rclone.exe mount ""remote:"" ""\\cloud\target"" --log-file ""C:\Tools\rclone-v1.71.2-windows-amd64\logs\remote.txt"" --no-console --vfs-cache-mode full"
    
    'Etc. add or remove as many as you like.
    
    'Dim and Set shell object:
    Dim oShell
    Set oShell = WScript.CreateObject ("WScript.shell")
    
    'For loop for (hidden) command execution:
    Dim command
    For Each command in Array(cmd1) 'Add all cmd variables to this array!   
        oShell.run command,0,false
    Next
    
    'Set object to Nothing as tradition:
    Set oShell = Nothing
  2. Create a bat file from the following template which will launch the vbs script (edit the path depending on where you store the script)

    @echo off
    WScript.exe "C:\Tools\scripts\rclone_automount.vbs"
  3. Add the bat file to the autostart directory of windows:

    C:\Users\USER\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup

Source: Github

This page was last edited on 2025-12-15 16:00

Powered by Wiki|Docs

This page was last edited on 2025-12-15 16:00

clippy
?

Powered by Wiki|Docs