View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 0001957 | 1003.1(2024)/Issue8 | Shell and Utilities | public | 2025-11-12 05:03 | 2025-12-11 16:21 |
| Reporter | Love4Boobies | Assigned To | |||
| Priority | normal | Severity | Editorial | Type | Enhancement Request |
| Status | Resolved | Resolution | Accepted As Marked | ||
| Name | Bogdan Barbu | ||||
| Organization | |||||
| User Reference | |||||
| Section | ex, vi | ||||
| Page Number | N/A | ||||
| Line Number | N/A | ||||
| Interp Status | --- | ||||
| Final Accepted Text | 0001957:0007334 | ||||
| Summary | 0001957: Standardize the -u option for ex/vi | ||||
| Description | According to the current standard, the ex utility (and vi, implicitly) looks for .exrc in the home directory. It would be desirable to allow for other locations in order to allow users to have different initialization files for different tasks. | ||||
| Desired Action | I propose that the -u option be standardized. This already exists in implementations like Vim and Neovim and does not seem to be used for anything else in other implementations that I've checked. It should specify a file to be used instead of the default .exrc file; if multiple -u options are specified then only the last one should apply. This is consistent with the mentioned implementations and is also very useful. For example, consider a user who wishes to keep their configuration files in accordance to the XDG basedir specification, which many programs today follow. They might do the following: alias vi='vi -u "${XDG_CONFIG_HOME:-$HOME/.config}/exrc"' If only the last -u option is used, they have the ability to override the alias. | ||||
| Tags | issue9 | ||||
|
|
On page 2838 line 94174 section ex (SYNOPSIS), change:[-t tagstring] [-w size] to: [-t tagstring] [-u rcfile] [-w size] On page 2839 line 94218 section ex (OPTIONS), after: Suppress the use of the EXINIT environment variable and the reading of any .exrc file; see the EXTENDED DESCRIPTION section. add a sentence: If the -u rcfile option is also specified, the use of the specified rcfile shall not be suppressed. After page 2839 line 94224 section ex (OPTIONS), add: -u rcfile On page 2839 line 94242 section ex (INPUT FILES), change: The .exrc files and source files shall be text files consisting of ex commands; see ... to: The .exrc files, a file specified with the -u rcfile option, and files specified with a :source command shall be text files consisting of ex commands; see ... On page 2843 line 94409 section ex (EXTENDED DESCRIPTION), change: If the environment variable EXINIT is set, the editor shall execute ... to: If the environment variable EXINIT is set and the -u rcfile option is not specified, the editor shall execute ... On page 2843 line 94411 section ex (EXTENDED DESCRIPTION), change: If the EXINIT variable is not set, and all of the following are true to: If the EXINIT variable is not set, the -u rcfile option is not specified, and all of the following are true On page 2843 line 94419 section ex (EXTENDED DESCRIPTION), change: If and only if all of the following are true to: If and only if the -u rcfile option is not specified and all of the following are true After page 2844 line 94429 section ex (EXTENDED DESCRIPTION), add: 4. On page 2844 line 94430 section ex (EXTENDED DESCRIPTION), change: Lines in any .exrc file that are blank lines shall be ignored. to: Lines in any .exrc file, or a file specified using -u rcfile, that are blank lines shall be ignored. On page 2844 line 94432 section ex (EXTENDED DESCRIPTION), change: After the EXINIT variable and any .exrc files are processed ... to: After the EXINIT variable and any .exrc files or a file specified using -u rcfile are processed ... On page 2849 line 94684 section ex (EXTENDED DESCRIPTION), change: Otherwise, if the ex command resulted from the processing of an EXINIT environment variable, a .exrc file, a :source command, ... to: Otherwise, if the ex command resulted from the processing of an EXINIT environment variable, a .exrc file, a -u rcfile option, a :source command, ... On page 3526 line 120384 section vi (SYNOPSIS), change: [-t tagstring] [-w size] to: [-t tagstring] [-u rcfile] [-w size] After page 3526 line 120411 section vi (OPTIONS), add: -u rcfile |
| Date Modified | Username | Field | Change |
|---|---|---|---|
| 2025-11-12 05:03 | Love4Boobies | New Issue | |
| 2025-12-11 16:19 | geoffclare | Note Added: 0007334 | |
| 2025-12-11 16:21 | geoffclare | Status | New => Resolved |
| 2025-12-11 16:21 | geoffclare | Resolution | Open => Accepted As Marked |
| 2025-12-11 16:21 | geoffclare | Interp Status | => --- |
| 2025-12-11 16:21 | geoffclare | Final Accepted Text | => 0001957:0007334 |
| 2025-12-11 16:21 | geoffclare | Tag Attached: issue9 |