[arm-allstar] How difficult would it be to maybe add this feature to a future update to the audio archive feature?

Doug Crompton wa3dsp at gmail.com
Fri Jan 5 11:03:09 EST 2018


Terry,

 What you want to do could be accomplished with a script as you mentioned
which would probably be a better way to do it. Things that can be done
outside of Allstar are best done that way. This would be done with a cron
job run once a day to create a folder and copy all files for that day to
it. Here is a novel way to do it without writing some long script -

https://stackoverflow.com/questions/9622883/recursive-copy-of-specific-files-in-unix-linux

rsync -avm --include='*.jar' -f 'hide,! */' . /destination_dir

​And maybe changed to something like this which should copy all
<current_date.txt> files to the /<current_date directory>​  Change the .txt
to whatever the name extension is or .* for all files.

​rsync -avm --include=​
​`​
echo date +%Y%m%d.txt
​`​ -f 'hide,! */' . `echo date +/%Y%m%d"


This could be run once at 2359 in a cron job. A better way would be to do
it at some time AFTER midnight and use -

`echo date -d "yesterday" +%Y%m%d.xxx`

Also be sure that you recognize that the characters around the echo date
are not an apostrophe it is a back quote - to the left of the numeral 1 on
the keyboard.

In Linux there are numerous ways to do the same task and this might not be
the best way but it is simple and could probably be expanded on. I suggest
you try this. You can add the -n to rsync or -avmn  to just try doing it
without creating the files in experimenting.

Let me know if you need more help with this.


*73 Doug*

*WA3DSP*

*http://www.crompton.com/hamradio <http://www.crompton.com/hamradio>*



On Fri, Jan 5, 2018 at 3:35 AM, "Terry Bethlehem via arm-allstar" <
arm-allstar at hamvoip.org> wrote:

> For me, I'd like a feature that creates a folder, on your external drive,
> each day, with its contents. Say for example, at midnight, the pi creates a
> folder named 20180105, and dumps all the audio files in it. When the next
> day comes, it creates a new folder then dumps the files in the new folder.
> I don't know how many people that actually use this feature, would really
> like this or don't care. I archive all the files, to my pc, when my node is
> offline for the day. I create folders with the date. I scroll through
> thousands of files, for a single day, to move them to the appropriate date
> folder I created on my pc. Automating this would be awesome for me. I don't
> know how many agree with my suggestion. I also know you guys have other
> things you're trying to improve and implement.
>
> Any input is appreciated. I'm just wishing for a little bit of automated
> housekeeping, instead of plowing through thousands of wav files, trying to
> find what I'm looking for. I'm not a scripter yet.
> _______________________________________________
>
> arm-allstar mailing list
> arm-allstar at hamvoip.org
> http://lists.hamvoip.org/cgi-bin/mailman/listinfo/arm-allstar
>
> Visit the BBB and RPi2/3 web page - http://hamvoip.org
>


More information about the arm-allstar mailing list