Posts by zebrom

    I have a HTPC my parents use without an internet connection. To add new files I go over there with a usb drive and file manager to put them on the htpc. I'd like to set it up so that when the usb drive is plugged in a script will run that will move the contents of the directory on the usb drive to the directory where I keep the media on the htpc. I don't know much about linux but i found this command that may help:

    Quote
    Bash
    #!/bin/bash
    mv /path/to/source /path/to/destination


    For example if the usb folder is /dev/sdb/movies and i want to move the contents to the htpc folder which is /dev/sda/movies the command would look like this.

    Quote


    #!/bin/bash
    mv /dev/sdb/movies /dev/sda/movies


    Is this correct? Does anything need to be changed? What kind of file extension should I give it? I'm creating this on a windows machine.

    Thanks to anyone that helps.