More > JRiver Media Center 29 for Linux

JRiver Media Center 29.0.18 for Debian Buster (amd64, i386, arm64 and armhf)

<< < (3/5) > >>

mwillems:

--- Quote from: BryanC on March 11, 2022, 12:17:17 pm ---It makes no difference really. rsync just creates the missing destination directory automatically so it's one less line of code.


--- Code: ---MVERSION=29
migrateLibrary() {
    debug "Running: ${FUNCNAME[0]}"

    declare mc_user_path="$HOME/.jriver"
    declare current_config_path="$mc_user_path/Media Center $MVERSION"
    declare previous_config_path="$mc_user_path/Media Center $(( MVERSION - 1 ))"

    if [[ ! -d "$current_config_path" ]] &&
    [[ -d "$previous_config_path" ]] &&
    mkdir -p "$current_config_path"; then
        echo "Migrating $previous_config_path to $current_config_path"
        cp -a "$previous_config_path" "$current_config_path" &>/dev/null
    fi
}

--- End code ---

--- End quote ---

cp -a makes the destination folder for me, but won't make parent folders if they're missing, so it worked without a mkdir here just fine (and likely would on any installation that already has a .jriver directory).  But you're right, if there's no .jriver folder at all rsync deals with that failure mode.

bob:

--- Quote from: BryanC on March 11, 2022, 09:02:06 am ---When is the config directory created? On first run or during package install? I'm adding migration to installJRMC (for single version increments, good enough for now).


--- Code: ---MVERSION=29
migrateLibrary() {
    debug "Running: ${FUNCNAME[0]}"

    declare mc_user_path="$HOME/.jriver"
    declare current_config_path="$mc_user_path/Media Center $MVERSION"
    declare previous_config_path="$mc_user_path/Media Center $(( MVERSION - 1 ))"

    if [[ ! -d "$current_config_path" ]] &&
    [[ -d "$previous_config_path" ]]; then
        echo "Migrating $previous_config_path to $current_config_path"
        rsync -a "$previous_config_path" "$current_config_path" &>/dev/null
    fi
}

--- End code ---

--- End quote ---
During first run.
Also the skins, data, visualizations, are copied from the install directory into the users directory on first run.
If there is data there already you shouldn't copy over it.

Ekpen:
link is not working.
Sent a PM thinking it will get to you faster than sending you a message in the forum.
Remy and those writing are probably your testers.

George.

RemyJ:

--- Quote from: Ekpen on March 11, 2022, 01:54:45 pm ---link is not working.
Sent a PM thinking it will get to you faster than sending you a message in the forum.
Remy and those writing are probably your testers.

George.

--- End quote ---

The links at the top of the page are all working for me without any login.
Which one specifically isn't working?

bob:
Hi George, I PM'd you back as well.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version