Check-in [a4a3ebcbb3]

Login
Bounty program for improvements to Tcl and certain Tcl packages.
Tcl 2019 Conference, Houston/TX, US, Nov 4-8
Send your abstracts to [email protected]
or submit via the online form by Sep 9.

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Minor editorial corrections to 431 formatting
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: a4a3ebcbb39a98a2b02dc95572fbacaeae33d7ba5a0439bf26bdbbd5c29afd2f
User & Date: dkf 2018-05-27 11:33:15
Context
2018-05-28
08:36
tip454(resize frame on last child remove): withdrawn due to critical incompatibility. Should be restarted with alternate solution or in Tk 9.0 check-in: 660df61ab3 user: oehhar tags: trunk
2018-05-27
11:33
Minor editorial corrections to 431 formatting check-in: a4a3ebcbb3 user: dkf tags: trunk
10:50
Fix markdown formatting issue check-in: 230d2e87e1 user: dkf tags: trunk, minor change
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to tip/431.md.

     1      1   # TIP 431: Add 'tempdir' Subcommand to 'file'
     2      2   	Author:		Kevin Pasko <[email protected]>
     3      3   	State:		Draft
     4      4   	Type:		Project
     5      5   	Tcl-Version:	8.6.4
     6      6   	Vote:		Pending
     7         -	Created:		10-Sep-2014
            7  +	Created:	10-Sep-2014
     8      8   	Keywords:	Tcl, directory, file
     9      9   	Post-History:
    10     10   -----
    11     11   
    12     12   # Abstract
    13     13   
    14     14   This TIP proposes adding a new **tempdir** subcommand to the **file**
................................................................................
    22     22   without the possibility of race conditions.
    23     23   
    24     24   # Specification
    25     25   
    26     26   The **file tempdir** command shall implement the functionality of the POSIX
    27     27   standard mkdtemp\(\) function. With no arguments **file tempdir** shall create
    28     28   a uniquely named temporary directory in the native operating system's
    29         -temporary directory, with naming convention "**tcl\_**_XXXXXX_" where each
           29  +temporary directory, with naming convention "<b>tcl\_</b><i>XXXXXX</i>" where each
    30     30   _X_ is a randomly selected character \(following the **file tempfile**
    31     31   naming convention\). Successful completion of **file tempdir** shall return
    32     32   the absolute path of the created directory, otherwise an error shall be
    33     33   thrown.
    34     34   
    35     35   **file tempdir** shall have an optional argument, _template_, to modify
    36     36   the created directory's path and name. The _template_ shall be decomposed
    37     37   into \(up to\) two parts: the directory's path and rootname. If either part is
    38     38   absent, relevant defaults \(e.g., according to the native operating system\)
    39     39   shall be used. The entire temporary name shall then be formed from the path,
    40         -the root, and a generated unique string of \(typically\) six characters.
           40  +the root, and a generated unique string of \(typically\) six characters. If
           41  +the directory part of the _template_ is supplied, it should refer to a
           42  +directory on the native filesystem.
    41     43   
    42     44   The command syntax should be defined as:
    43     45   
    44     46    > **file tempdir** ?_template_?
    45     47   
    46     48   # Considerations
    47     49   
    48     50    * The subcommand **tempdir** could be a candidate, later, for returning the
    49     51      native file system's temporary directory. Naming the subcommand something
    50     52      else such as **mktempdir** is another option, though strays from the **file
    51     53      tempfile** naming convention.
    52     54   
    53         - * For future extensibility the **template** argument to **file tempdir**
           55  + * For future extensibility the _template_ argument to **file tempdir**
    54     56      \(since it is optional\) could be specified in the key / value format,
    55         -   **-template**, changing the command syntax to:
           57  +   **-template** _template_, changing the command syntax to:
    56     58   
    57         -	 > > **file tempdir** ?_options..._?
           59  +	 > **file tempdir** ?_options..._?
    58     60   
    59     61   # Reference Implementation
    60     62   
    61     63   An example of temporary directory creation has already been developed into the
    62     64   Tcl core, at the C level, within the platform specific layers of the
    63     65   **load** command. The principal work remaining is to expose this via a Tcl
    64     66   command.
    65     67   
    66     68   # Copyright
    67     69   
    68     70   This document has been placed in the public domain.
    69     71