Synchronet v3.19b-Win32 (install) has been released (Jan-2022).

You can donate to the Synchronet project using PayPal.

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
module:addfiles [2021/04/17 00:22] – [Invoke] Updated usage syntax/help output digital manmodule:addfiles [2024/12/05 01:11] (current) – Update the help output to match current script digital man
Line 1: Line 1:
 ====== Add Files ====== ====== Add Files ======
-New for Synchronet v3.19, this JavaScript utility script replaces the functionality of the old ADDFILES program.+New for Synchronet v3.19, this JavaScript utility script replaces the functionality of the old [[util:ADDFILES]] program.
  
 This script can import files into one or more filebases either using input filename/description lists (e.g. ''FILES.BBS'') or by just searching for files in the directory's storage path and using any descriptions embedded in each file's archive (e.g. ''FILE_ID.DIZ''). This script can import files into one or more filebases either using input filename/description lists (e.g. ''FILES.BBS'') or by just searching for files in the directory's storage path and using any descriptions embedded in each file's archive (e.g. ''FILE_ID.DIZ'').
Line 8: Line 8:
 ===== Invoke ====== ===== Invoke ======
 Run with [[util:JSexec]] Run with [[util:JSexec]]
-  jsexec addfiles.js+  jsexec addfiles -help
  
 <file> <file>
-usage: [-options] [dir-code] [listfile]+usage: [dir-spec] [-options] [listfile] [desc-off] 
 + 
 +dir-spec: 
 +  -all              Add files in all directories of all libraries (implies -auto) 
 +  -lib=<name>     * Add files in all directories of specified library (implies -auto) 
 +  -dir=<code>,... * Add files in multiple specified directories 
 +   dir-code         Internal code of (one and only) directory to add files to 
 +                  * indicates parameters that can be combined and/or specified multiple times 
 +   Note: If no directories are specified, one will be prompted for. 
 options: options:
-  -all            add files in all libraries/directories (implies -auto+  -auto             Add files only to directories that have Auto-ADDFILES enabled (in SCFG
-  -lib=<name>     add files in all directories of specified library (implies -auto+  -from=<name>      Specify uploader's user name (may require quotes
-  -from=<name>    specify uploader's user name (may require quotes) +  -file=<name>      Specify files to add (wildcards supported, default: *
-  -ex=<filename>  add to excluded filename list +  -ex=<filename>    Add to excluded filename list 
-                  (default: FILES.BBS,FILE_ID.DIZ,DESCRIPT.ION,SFFILES.BBS) +                    (default: FILES.BBS,DESCRIPT.ION,00_INDEX.TXT,SFFILES.BBS,FILE_ID.DIZ
-  -diz            always extract/use description in archive +  -diz              Always extract/use description in archive (e.g. FILE_ID.DIZ) 
-  -update         update existing file entries (default is to skip them) +  -update           Update existing file entries (default is to skip them) 
-  -date[=fmt]     include today's date in description +  -readd            Re-add existing file entries (so they appear as newly-uploaded 
-  -fdate[=fmt]    include file's date in description +  -date[=fmt]       Include today's date in description 
-  -adate[=fmt]    include newest archived file date in description +  -fdate[=fmt]      Include file's date in description 
-                  (fmt = optional strftime date/time format string) +  -adate[=fmt]      Include newest archived file date in description 
-  -delete         delete list after import +                    (fmt = optional strftime date/time format string) 
-  -v              increase verbosity of output +  -delete           Delete list after import 
-  -debug          enable debug output+  -v                Increase verbosity of output 
 +  -debug            Enable debug output 
 + 
 +optional listfile parameters: 
 +   listfile         Name of listfile to import (e.g. FILES.BBS) 
 +   desc-off         Description character-offset in listfile (e.g. 40)
 </file> </file>
- 
-If no options or directories are specified, the sysop will be prompted for a directory to add files to. 
  
 ==== Examples ==== ==== Examples ====
Line 42: Line 54:
   jsexec addfiles -lib=main FILES.BBS   jsexec addfiles -lib=main FILES.BBS
      
 +* To add files/descriptions from a ''FILES.BBS'' list (where file descriptions begin at column 40) for the //graphics// directory: 
 +  jsexec addfiles graphics FILES.BBS 40 
 +   
 +* To add files to a specific directory (//graphics//) using embedded descriptions (e.g. ''FILE_ID.DIZ'') //without// a list file: 
 +  jsexec addfiles graphics -diz
 ===== See Also ===== ===== See Also =====
   * [[:module:|module index]]   * [[:module:|module index]]