Skip to content

Session Options

PhilLast edited this page Jan 16, 2020 · 14 revisions

This page is now completely redundant.

Navigate this page:

Overview

All acre commands return a result, and some - when appropriate - issue messages. Acre allows you to control certain other behaviour by setting modifiers and flags.

All flags and modifiers revert to their default before each command so have to be set simultaneously with each command they are intended to affect.

Shortcuts

Dyalog user commands allow to specify as few characters as needed to distinguish it from any other user commands. The same holds true for options and flags. Since all acre flags implemented for a particular command start with a different letter you may actually use a single letter. For example, rather than specifying -help just -h would do as well.

Asking for help

Although acre supports the default help mechanism of the Dyalog user command interface (One to three question marks to the right of the opening ] or -? at the end of a user command from version 17.0 onwards) there is also a -help flag available, for example:

]acre.CreateProject -help

Flags available

Tracking changes

The OpenProject command accepts the -track flag which is On by default. The only relevance in using this is to set it Off as

      ]OpenProject path/ [#.target] -track=off

The code will be loaded as usual but changes to it via the editor will not be saved to the project and acre commands will not recognise the ProjectSpace as containing an open project.

The -track modifier may also be specified in the entries of the Open← configuration parameter

   Open←'ProjectA' 'ProjectB/ -track=off'

The dependencies of a project that is not tracked will not be tracked however specified.

Controlling dependencies

The OpenProject command accepts the -dependencies flag which is On by default. The only relevance in using this is to set it Off as

      ]OpenProject path/ [#.target] -dependencies=off

The code will be loaded as usual but the Open← configuration parameter will be ignored. The -dependencies modifier has no effect on the -track modifier.

The -dependencies modifier may also be specified in the entries of the Open← configuration parameter

   Open←'ProjectA' 'ProjectB/ -dependencies=off'

Case-coding file and folder names

The CreateProject command accepts the -casecode flag which is Off by default. The Casecode=On/Off configuration parameter will be set in the configuration file correspondingly and can be changed subsequently. The only reason to include it is to set it On.

      ]CreateProject path/ #[.target] -casecode=On

The project will be created with all source file and folder names suffixed with a casecode.

Keeping local history

The CreateProject command accepts the -keephistory flag which is Off by default. The KeepHistory=On/Off configuration parameter will be set in the configuration file correspondingly and can be changed subsequently. The only reason to include it is to set it On.

      ]CreateProject path/ #[.target] -keephistory=On

Changes to items in the editor will be saved to a local history folder in addition to the source folder. The Changes, ]Restore, ]Undo, ]Redo and ]PurgeHistory commands will be enabled.

Reporting and restricting date-times

The Changes and Projects commands accept the -when flag or modifier.

When Changes is applied to an entire project the -when flag adds the date-time of the last change to each item.

      ]changes #.project -when
#.project.itemA 2018-11-29 13:58:08
#.project.itemB 2018-11-18 09:47:23

The -when=datetime modifier restricts the output to only those changed since that time.

      ]changes #.project -when=20181120
#.project.itemA 2018-11-29 13:58:08

Applied to a single item the -when flag causes only the version and date-times to be shown.

      ]changes #.project.itemA -w
  >>>  Version   2  Saved: 2018-11-29 13:58:08
       Version   1  Saved: 2018-11-28 16:12:55

The -when=datetime modifier restricts the output to the version, date-time and value of each change to that item since that time.

      ]changes #.project.itemA -w=20181129
  >>>  Version   2  Saved: 2018-11-29 13:58:08
   itemA←{⍺←⊢
       ⍺ ⍺⍺⊢⍵
  ⍝ comment some more
   }

The -when flag applied to the Projects command adds the date-time of the most recent opening or refreshing to each project-space and project-folder displayed.

      ]projects -when
 #.test     C:/Users/user/projects/test/     2018-11-29 14:12:10
 #.project  C:/Users/user/projects/project/  2018-11-29 14:15:51