Project

General

Profile

Actions

Feature #12675

closed

Move command line history to a GUI option stored in ``config.xml`` rather than a manual flag file

Added by Steve Wheeler about 2 years ago. Updated almost 2 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
Configuration Backend
Target version:
Start date:
Due date:
% Done:

100%

Estimated time:
Plus Target Version:
22.05
Release Notes:
Default

Description

Currently the CLI history is retained if the file .keephistory is present.

It would be nice if that option was retained as a config setting so that it is restored with that after a re-install.


Related issues

Related to Feature #11029: Enable command history in the shellResolvedJim Pingle11/03/2020

Actions
Related to Bug #14490: ~/.tcshrc needs cleaning up...Not a Bug

Actions
Actions #1

Updated by Viktor Gurov about 2 years ago

Maybe it's better to add an option to the WebGUI?

Actions #2

Updated by Steve Wheeler about 2 years ago

Sure that would be even better.

Actions #3

Updated by Jim Pingle about 2 years ago

It would need to be on the per-user settings since the file would need to be synchronized to each separate user account with shell privileges.

Actions #5

Updated by Jim Pingle about 2 years ago

  • Status changed from New to Pull Request Review
  • Target version changed from CE-Next to 2.7.0
  • Plus Target Version changed from Plus-Next to 22.05
Actions #6

Updated by Jim Pingle about 2 years ago

  • Assignee set to Viktor Gurov
Actions #7

Updated by Viktor Gurov about 2 years ago

  • Status changed from Pull Request Review to Feedback
  • % Done changed from 0 to 100
Actions #8

Updated by Jim Pingle about 2 years ago

  • Status changed from Feedback to New

The MR implemented the config setting/backend part but not the GUI option. And now if the user touches the file manually it gets cleared at the next boot, so there is no way to retain the setting from the GUI.

Additionally, even with the value set in the user it doesn't appear to work. The ~/.keephistory file is not present in /root/ when the admin user has the option in its config.xml section.

Actions #9

Updated by Jim Pingle about 2 years ago

  • Status changed from New to In Progress
  • Assignee changed from Viktor Gurov to Jim Pingle
Actions #10

Updated by Jim Pingle about 2 years ago

  • Status changed from In Progress to Feedback

I merged a fix for the option check and also added a GUI option when editing the user. Will be in snapshots soon.

Actions #11

Updated by Viktor Gurov about 2 years ago

Jim Pingle wrote in #note-10:

I merged a fix for the option check and also added a GUI option when editing the user. Will be in snapshots soon.

commit: https://github.com/pfsense/pfsense/commit/98ecfb9f840bf561ce204d0cca4ec88486e1ea33

works as expected

Actions #12

Updated by Viktor Gurov about 2 years ago

  • Status changed from Feedback to New

Jim Pingle wrote in #note-8:

nd now if the user touches the file manually it gets cleared at the next boot, so there is no way to retain the setting from the GUI.

fix:
https://gitlab.netgate.com/pfSense/pfSense/-/merge_requests/678

Actions #13

Updated by Jim Pingle almost 2 years ago

  • Status changed from New to In Progress

Taking another look at this, there is no need to use the flag file at all now. It can be read directly from the config. I'm going to commit a change to handle it that way. It's worked fine in testing so far.

Actions #14

Updated by Jim Pingle almost 2 years ago

  • Status changed from In Progress to Feedback
Actions #15

Updated by Jim Pingle almost 2 years ago

  • Subject changed from Keep command line history as a config option to Move command line history to a GUI option stored in ``config.xml`` rather than a manual flag file

Updating subject for release notes.

Actions #16

Updated by Jim Pingle almost 2 years ago

  • Status changed from Feedback to Resolved

This is working very well. Option is active after config restore, it's only in the config, no more flag file. All OK.

Actions #17

Updated by Jim Pingle 9 months ago

  • Related to Feature #11029: Enable command history in the shell added
Actions #18

Updated by Jim Pingle 9 months ago

  • Related to Bug #14490: ~/.tcshrc needs cleaning up... added
Actions

Also available in: Atom PDF