AddToFile.CMD

From OS2World.Com Wiki
Revision as of 03:35, 13 January 2021 by Martini (talk | contribs) (Created page with " ==Syntax== Usage: AddToFile.cmd FileName,String,Function[,Parameters...] Functions: DATEL - Adds the date as a long number. DATE1 - Adds the date in 2017-Jul-01 format...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Syntax

Usage:

 AddToFile.cmd FileName,String,Function[,Parameters...]

Functions:

 DATEL - Adds the date as a long number.
 DATE1 - Adds the date in 2017-Jul-01 format.
 BLDLEVEL - Adds a standardized formatted BLDLEVEL string.
 DATEYEAR - Adds the current year.
 DATEMONTH - Adds the current month.
 DATEDAY - Adds the current day.
 VERSIONMAJOR - Adds the major portion of the provided version number.
 VERSIONMINOR - Adds the minor portion of the provided version number.
 VERSIONREVISION - Adds the revision portion of the provided version number.
 STRING - Adds the string with %Y substitution.
 VAR - Adds the value of the specified variable from a specified file.
 FILE - Adds the contents of a file.

Examples: --- AddToFile.cmd AddToFile.tmp,#define DDATE,DATEL

  1. define DDATE 20210112L

--- AddToFile.cmd AddToFile.tmp,#define DDATE,DATE1

  1. define DDATE 2021-Jan-12

--- AddToFile.cmd AddToFile.tmp,option description,BLDLEVEL,Vendor,1.2.3,Description,Fixpack,Asd option description '@#Vendor:1.2.3#@##1## 12 Jan 2021 16:06:11 ARCAOS-V  :Asd:::3::Fixpack@@Description' --- AddToFile.cmd AddToFile.tmp,char *bl = "%A";,BLDLEVEL,Vendor,1.2.3,Description,Fixpack char *bl = "@#Vendor:1.2.3#@##1## 12 Jan 2021 16:06:11 ARCAOS-V  ::::3::Fixpack@@Description"; --- AddToFile.cmd AddToFile.tmp,#define DYEAR,DATEYEAR

  1. define DYEAR 2021

--- AddToFile.cmd AddToFile.tmp,#define DMONTH,DATEMONTH

  1. define DMONTH 1

--- AddToFile.cmd AddToFile.tmp,#define DDAY,DATEDAY

  1. define DDAY 12

--- AddToFile.cmd AddToFile.tmp,#define DVMAJ,VERSIONMAJOR,1.02.03

  1. define DVMAJ 1

--- AddToFile.cmd AddToFile.tmp,#define DVMIN,VERSIONMINOR,1.02.03

  1. define DVMIN 2

--- AddToFile.cmd AddToFile.tmp,#define DVREV,VERSIONREVISION,1.02.03

  1. define DVREV 3

--- AddToFile.cmd AddToFile.tmp,#define DSTRING,STRING,The year is %Y

  1. define DSTRING The year is 2021

--- AddToFile.cmd AddToFile.tmp,#define XYZ "%A",VAR,EXAMPLEVAR=,AddToFile.cmd

  1. define XYZ ""

--- AddToFile.cmd AddToFile.tmp,InFileName,FILE