Opened 12 years ago

Closed 11 years ago

#3399 closed defect (obsolete)

sugar-jhbuild shell should change the prompt

Reported by: manuq Owned by: sascha_silbe
Priority: Unspecified by Maintainer Milestone: Unspecified
Component: sugar-jhbuild Version: Unspecified
Severity: Unspecified Keywords:
Cc: Distribution/OS: Unspecified
Bug Status: Unconfirmed


This will prevent confusions while working inside a Sugar shell. The PS1 variable should change to identify it.

Proposal: prefixing PS1 with '(sugar)', like:

[humitos] [~/sugar]$ PS1=(sugar)$PS1
(sugar)[humitos] [~/sugar]$

Besides, we should save the old PS1 to be able to restore it when the
user closes the "sugar" session.

Attachments (1)

0001-PS1-variable-for-shell-command.patch (968 bytes) - added by humitos 12 years ago.

Download all attachments as: .zip

Change History (5)

comment:1 Changed 12 years ago by humitos

I was taking a look at this, and it's no trivial because that variable is set by ~/.bashrc or /etc/bash.bashrc. So, if we set this variable in the sugar config script; it will be override when that script was called (after os.execlp call).

Changed 12 years ago by humitos

comment:2 Changed 12 years ago by humitos

The patch attached only works if the user doesn't have set the PS1 variable but that is not so common.

That patch shows where we should set the PS1 environment variable, at least :)

comment:3 Changed 12 years ago by manuq

  • Component changed from sugar-datastore to sugar-jhbuild

comment:4 Changed 11 years ago by manuq

  • Resolution set to obsolete
  • Status changed from new to closed

Closing as obsolete. We use sugar-build now.

Note: See TracTickets for help on using tickets.