• postfile.js should allow duplicates

    From Fernando Toledo@1:103/705 to GitLab issue in main/sbbs on Fri Dec 6 13:11:01 2024
    open https://gitlab.synchro.net/main/sbbs/-/issues/836

    I need to add a file to 2 file areas, one "local" and other "networked" fix tic/ftn

    I have to upload a file to both areas and then I regenerate it and have to overwrite it

    ```
    /sbbs/exec/jsexec postfile fidoz4daily zone4.341 "Z4 Daily Nodelist bla" Ragnarok
    /sbbs/exec/jsexec postfile fidozsegs zone4.341 "Z4 Nodelist bla" Ragnarok
    ```

    ```
    !File 'zone4.341' already added.
    !Module (postfile) set exit_code: 1
    ```

    What would be the best option?

    * Any chance that postfile can replace the current one (adding new option like -replace) ?
    * Should I delete it first?
    * Or could I use addfiles in this case?

    I know this creates a duplicate in my file database, but for now it is something desired.
    Thanks!
    --- SBBSecho 3.23-Linux
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Rob Swindell@1:103/705 to GitLab note in main/sbbs on Sun Dec 8 21:12:49 2024
    https://gitlab.synchro.net/main/sbbs/-/issues/836#note_6125

    If the file is already in the filebase, I'm clear not clear why you want to re-add it. Just to update the file description?
    --- SBBSecho 3.23-Linux
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Rob Swindell@1:103/705 to GitLab note in main/sbbs on Sun Dec 8 21:13:00 2024
    https://gitlab.synchro.net/main/sbbs/-/issues/836#note_6125

    If the file is already in the filebase, I'm not clear why you want to re-add it. Just to update the file description?
    --- SBBSecho 3.23-Linux
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Rob Swindell@1:103/705 to GitLab note in main/sbbs on Sun Dec 8 22:55:25 2024
    https://gitlab.synchro.net/main/sbbs/-/issues/836#note_6126

    If you just want update an existing file, there is the existing script: `updatefiles.js`, you could take a look at that/try it. It might make more sense to use that script (or one like it) rather than `postfiles.js` or `addfiles.js` to update an existing file description.
    --- SBBSecho 3.23-Linux
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Fernando Toledo@1:103/705 to GitLab note in main/sbbs on Mon Dec 9 08:02:00 2024
    https://gitlab.synchro.net/main/sbbs/-/issues/836#note_6127

    I regenerate the file, and must overrite it, so I need to update the file because size/description can be different
    --- SBBSecho 3.23-Linux
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)
  • From Fernando Toledo@1:103/705 to GitLab note in main/sbbs on Mon Dec 9 08:02:42 2024
    https://gitlab.synchro.net/main/sbbs/-/issues/836#note_6128

    I hadn't taken that into account, I'll check it out, thanks!
    --- SBBSecho 3.23-Linux
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)