Debian Codegraph @

cmsmvs/zipname.conven

raw
1
2 Zip file/directories name convention under MVS
3 ---------------------------------------------------
4 Draft 1.1
5
6
7 1. Translating native file names to Zip filenames.
8
9 1.1 Zipping a PDS
10
11 On MVS there are directories called PDS (Partition Data Set) which have
12 the following format : name1.name2.name3(mname)
13 for example: myuserid.unzip.c(unzip)
14
15 So as you see the path delimiter is '.'. Each dir name can be max 8
16 chars long beginning with a number.
17
18 Between '(' and ')' there is the so called member name - it is also 8
19 chars long. This is the actual file name.
20
21
22 1.1.1 Converting MVS PDS name to zip path/filename (status: not implemented)
23
24 The PDS name is converted to zippath as follows:
25 in the zip : name1/name2/mname.name3
26 becomes on MVS: name1.name2.name3(mname)
27
28
29 1.2 Unzipping as PDS (status: implemented)
30
31 When you unzip the file name myuserid/unzip/unzip.c the same process
32 is done backwards, so you get : myuserid.unzip.c(unzip)
33
34 Notice that the file extension is used as last dirname!
35
36
37 1.2 Unzipping to a different PDS (status: implemented)
38
39 You can also use -d option while unzipping for example:
40 unzip mytest myuserid/unzip/unzip.c -dnewdest.test
41
42 then the new name will become:
43 newdest.test.myuserid.unzip.c(unzip)
44
45 Second example:
46
47 unzip mytest myuserid/unzip/*.c -dnewdest.test
48
49 then you get a PDS:
50 newdest.test.myuserid.unzip.c(...)
51
52 with all *.c files in it.
53
54
55 1.3 Zipping a Sequential Dataset (status: not implemented)
56
57 Sequential dataset is a dataset with NO members.
58 Such a dataset is translated from native MVS to zip format by replacing
59 the '.' (points) with '/' (backslash).
60
61 Example:
62 on MVS: name1.name2.name3
63 becomes in the zip : name1/name2/name3
64
65 NOTE : The new filename in the zip has NO extension this way it can be
66 recognised as a Sequential dataset and not a PDS.
67 But this also means that all files in the zip archive that have
68 no extension will be unzipped as Sequential datasets!
69
70
71 1.4 Using a DDNAMES for input. (status: not implemented)
72
73 To use DDNAMES as input file names put a 'dd:' before the ddname:
74 example: zip myzip dd:name1 dd:name2 dd:sales
75
76 In the Zip archive the ddnames are saved as name.DDNAME so if you try
77 the example above you will get in your zip file (when listing it) :
78
79 ..size .. date time .. crc .. NAME1.DDNAME
80 ..size .. date time .. crc .. NAME2.DDNAME
81 ..size .. date time .. crc .. SALES.DDNAME
82
83
84 1.4 Using a DDNAMES as zip name (status: implemented)
85
86 It is allowed to use a DDNAME as zipfile, just put dd: before it
87 example: unzip dd:myzip *.c
88 this will unzip all .c files from ddname myzip
89
90 example2: ZIP DD:MYZIP DD:MANE1 MYSOURCE.C MYDOC.TEXT(ZIPPING)
91 this will zip ddname name1 file mysource.c and PDS mydoc.text(zipping)
92 into as a zip file in the ddname myzip
93
94
95 2. Converting longer path names (unix like) (status: not implemented)
96 to native MVS names.
97
98 When in the zip archive there are dirnames longer that 8 chars they are
99 chopped at the 8 position. For example
100 MyLongZippath/WithLongFileName.text
101 is translated to:
102 MYLONGZI.TEXT(WITHLONG)
103
104 Notice that all chars are converted to uppercase.
105
106
107 2.1 Using special characters (status: implemented)
108
109 Also all '_' (underscore), '+' (plus), '-' (minus), '(' and ')'
110 from the file name/path in the zip archive are skipped because they
111 are not valid in the MVS filenames.
112
113
114 2.2 Numeric file names (status: not implemented)
115
116 On MVS no name can begin with a number, so when a dir/file name begins with
117 one, a leading letter 'N' is inserted. For example:
118 Contents.512
119 becomes:
120 CONTENTS.N512
121
122
123
124
125 Zip file/directories name convention under VM/CMS
126 ---------------------------------------------------
127
128 1. Translating native file names to Zip filenames.
129
130 On VM/CMS (not ESA ) there are NO directories so you got only disks
131 and files.
132
133 The file names are delimited with spaces. But for use with unzip/zip
134 you have to use '.' points as delimiters.
135
136 For example on your A disk you have file called PROFILE EXEC
137 if you want to zip it type : zip myzip profile.exec
138
139 If the same file is on your F disk you have to type:
140 zip myzip profile.exec.f
141
142 So as you can see the general format is fname.ftype.fmode
143
144 In the zipfile the disk from which the file comes is not saved!
145 So only the fname.ftype is saved.
146
147 If you unzip and you want to give a different destination disk just use
148 the -d option like:
149
150 unzip mytest *.c -df
151
152 This will unzip all *.c files to your F disk.
153
154
155 2. Converting longer path names (unix like) to native VM/CMS names.
156
157 When in the zip archive there are dirnames longer that 8 chars they are
158 chopped at the 8 position. Also the path is removed. For example
159 Zippath/WithLongFileName.text
160 is translated to:
161 WITHLONG.TEXT
162
163 Notice that all chars are converted to uppercase.
164
165 Also all '+' (plus), '-' (minus), '(' and ')'
166 from the file name/path in the zip archive are skipped because they
167 are not valid in the VM/CMS filenames.
168
169 If there is no extension for the file name in the zip archive, unzip
170 will add .NONAME for example:
171 mypath/dir1/testfile
172 becomes:
173 TESTFILE.NONAME
174
175 3. Future?
176
177 There is also discussion for a new option on ZIP that you can give
178 a virtual directory to be added before each file name that is zipped.
179
180 For example you want to zip a few .c file and put them in the zip
181 structure under the directory 'mydir/test', but you can't create dirs on
182 VM/CMS so you have to the something like:
183
184 ZIP myzip file1.c file2.c -dmydir/test
185
186 and you get in the zip archive files:
187
188 mydir/test/file1.c
189 mydir/test/file2.c
190
191 -------------------------------------------------------------------------
192
193
194 NOTE: Not all of those functions are implemented in the first beta
195 release of VM/MVS UNZIP/ZIP.
196
197 Every ideas/corrections/bugs will be appreciated.
198 Mail to maillist: [email protected]
199
200 George Petrov