diary

Diary of a session.

Syntax

  • diary()

  • diary(filename)

  • diary('off')

  • diary('on')

  • onoff = diary('get', 'Diary')

  • filename = diary('get', 'DiaryFile')

  • diary('set', 'DiaryFile', filename)

  • diary('set', 'Diary', onoff)

Input argument

  • onoff - a string: 'on' or 'off'.

  • filename - a string: filename of the current diary.

Output argument

  • onoff - a string: 'on' or 'off'.

  • filename - a string: filename to use for the diary.

Description

diary creates a log of keyboard input and the resulting text output.

diary toggles diary mode on and off.

diary('off') stops recording the session in the diary file.

diary('on') starts recording a session in a file called 'diary' in the current working directory.

diary('set', 'Diary', onoff) allows to start or stop the diary.

onoff = diary('get', 'Diary') returns the state 'on' or 'off' of the diary.

diary(filename) records the session in the file named filename.

filename = diary('get', 'DiaryFile') returns filename used as diary.

diary('set', 'DiaryFile', filename)) set the filename for the diary.

Example

filename = diary('get', 'DiaryFile')
onoff = diary('get', 'Diary')

See also

history.

History

Version
Description

1.0.0

initial version

Author

Allan CORNET

Last updated