Skip to content

Automating yabridgectrl sync via Bash scripting #466

@CSumm

Description

@CSumm

Thanks for giving yabridge a shot!

  • I read through both the troubleshooting and the known issues sections, and my issue wasn't listed there

Problem description

I am trying to find a way to automate yabridge whenever a file gets updated. I get to a point where the watched folder gets updated, but if using yabridgectrl sync, it'll continually nest yabridge folders into each other for each new file within a do while loop. I installed the inotifywait package. I tried using yabridgectrl sync --prune which prevents the nesting from happening, but it removes another folder I do not want to delete within their parent folder. Here is a code snippet I grabbed from the web to do the work:

# Run once at startup
yabridgectrl sync

# Wait for changes in the folder
inotifywait -m -r -e modify,create,delete,move "$FOLDER_TO_WATCH" |
while read -r directory events filename; do
    echo "Change detected: $filename, syncing..."
    yabridgectrl sync --prune
done

Do you have any advice on automating the process via Bash scripting? I tried to look online, and all resources point to doing it manually. Thanks in advance!

Operating system

Linux Mint 23

How did you install yabridge?

Directly from release pages

yabridge version

5.1.1

yabridgectl version

3.5.2

Wine version

9.21

Plugin

No response

Plugin type

None

Plugin architecture

None

Host

Reaper 7

Desktop environment or WM

No response

GPU model

No response

GPU drivers and kernel

No response

Debug log

No response

Anything else?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions