[Bug 1609342] Re: Gnome-terminal sets directory to HOME for ctrl-shift-n and custom shell command

2020-11-22 Thread Egmont Koblinger
gnome-terminal 3.36, which is included in Ubuntu 20.04, added a config
option Preferences ->  -> Command -> Preserve working
directory.

Older versions preserved the directory only when launching a shell, not
when launching a custom command. This behavior was frowned upon by some
folks, understandably.

The change is at https://gitlab.gnome.org/GNOME/gnome-
terminal/-/commit/79b2291 , the two bugtracker entries are linked from
the commit message.

Now, in order for this to work, two more things have to happen:
Whichever application (presumably your shell) is running in the source
window has to set the desired value, and whichever application is
starting up in the new window has to respect it (not intentionally
override it).

For setting: vte-2.91 is intended to do that, see its __vte_osc7()
method. Now there's a chance that some fragment in your shell profile
overrides it. To debug I recommend to manually issue the given escape
sequence and then not give back control to the shell, not to give it a
chance to override from PS1 or PROMPT_COMMAND or so:

  printf "\e]7;file:/etc\e\\" ; sleep 1000

A newly opened tab should be in /etc now. If this fixes the problem then
try it without the sleep. If that still fixes then your shell just
doesn't emit it. If removing the sleep breaks it again then there's
something in your prompt overriding the value.

To debug the other side: Set up a custom command of "sleep 2000", open a
new window, from another terminal locate the pid of this sleep, and
check its working directory at /proc//cwd. If this is set
correctly, yet it doesn't work your shell or custom command, then it's
that command intentionally switching to some other directory.

-- 
You received this bug notification because you are a member of Ubuntu
Desktop Bugs, which is subscribed to gnome-terminal in Ubuntu.
https://bugs.launchpad.net/bugs/1609342

Title:
  Gnome-terminal sets directory to HOME for ctrl-shift-n and custom
  shell command

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gnome-terminal/+bug/1609342/+subscriptions

-- 
desktop-bugs mailing list
desktop-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/desktop-bugs

[Bug 1609342] Re: Gnome-terminal sets directory to HOME for ctrl-shift-n and custom shell command

2020-11-22 Thread Egmont Koblinger
For setting: vte-2.91.sh is intended to do that... the ".sh" extension
was missing, sorry.

-- 
You received this bug notification because you are a member of Ubuntu
Desktop Bugs, which is subscribed to gnome-terminal in Ubuntu.
https://bugs.launchpad.net/bugs/1609342

Title:
  Gnome-terminal sets directory to HOME for ctrl-shift-n and custom
  shell command

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gnome-terminal/+bug/1609342/+subscriptions

-- 
desktop-bugs mailing list
desktop-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/desktop-bugs

[Bug 1609342] Re: Gnome-terminal sets directory to HOME for ctrl-shift-n and custom shell command

2020-11-20 Thread Yury V. Zaytsev
Hi,

So, this is affecting me on Ubuntu 20.04 - gnome-terminal no longer
preserves the current working directory in bash upon opening a new
window (or tab) from the context menu. Does anyone know what's going on?

The /etc/profile.d/vte-2.91.sh script is being sourced correctly, but I
believe that it only has to do with the pwd in the titlebar, which is
also working.

Switching to fish as proposed on StackOverflow is not an option... Any
tips? :-(

All the best,
Yury

-- 
You received this bug notification because you are a member of Ubuntu
Desktop Bugs, which is subscribed to gnome-terminal in Ubuntu.
https://bugs.launchpad.net/bugs/1609342

Title:
  Gnome-terminal sets directory to HOME for ctrl-shift-n and custom
  shell command

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gnome-terminal/+bug/1609342/+subscriptions

-- 
desktop-bugs mailing list
desktop-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/desktop-bugs

[Bug 1609342] Re: Gnome-terminal sets directory to HOME for ctrl-shift-n and custom shell command

2020-10-02 Thread Delmic
Still happening on Ubuntu 18.04, but in Ubuntu 20.04, gnome-terminal now
has an option to keep or not the working directory.

-- 
You received this bug notification because you are a member of Ubuntu
Desktop Bugs, which is subscribed to gnome-terminal in Ubuntu.
https://bugs.launchpad.net/bugs/1609342

Title:
  Gnome-terminal sets directory to HOME for ctrl-shift-n and custom
  shell command

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gnome-terminal/+bug/1609342/+subscriptions

-- 
desktop-bugs mailing list
desktop-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/desktop-bugs

[Bug 1609342] Re: Gnome-terminal sets directory to HOME for ctrl-shift-n and custom shell command

2016-08-30 Thread Alberto Salvia Novella
** Changed in: gnome-terminal (Ubuntu)
   Importance: Undecided => Medium

** Changed in: gnome-terminal (Ubuntu)
   Importance: Medium => Low

-- 
You received this bug notification because you are a member of Ubuntu
Desktop Bugs, which is subscribed to gnome-terminal in Ubuntu.
https://bugs.launchpad.net/bugs/1609342

Title:
  Gnome-terminal sets directory to HOME for ctrl-shift-n and custom
  shell command

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gnome-terminal/+bug/1609342/+subscriptions

-- 
desktop-bugs mailing list
desktop-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/desktop-bugs


[Bug 1609342] Re: Gnome-terminal sets directory to HOME for ctrl-shift-n and custom shell command

2016-08-04 Thread Zwinkau
For workarounds, see Stackoverflow:
http://unix.stackexchange.com/q/299989/123188

-- 
You received this bug notification because you are a member of Ubuntu
Desktop Bugs, which is subscribed to gnome-terminal in Ubuntu.
https://bugs.launchpad.net/bugs/1609342

Title:
  Gnome-terminal sets directory to HOME for ctrl-shift-n and custom
  shell command

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gnome-terminal/+bug/1609342/+subscriptions

-- 
desktop-bugs mailing list
desktop-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/desktop-bugs


[Bug 1609342] Re: Gnome-terminal sets directory to HOME for ctrl-shift-n and custom shell command

2016-08-03 Thread Launchpad Bug Tracker
Status changed to 'Confirmed' because the bug affects multiple users.

** Changed in: gnome-terminal (Ubuntu)
   Status: New => Confirmed

-- 
You received this bug notification because you are a member of Ubuntu
Desktop Bugs, which is subscribed to gnome-terminal in Ubuntu.
https://bugs.launchpad.net/bugs/1609342

Title:
  Gnome-terminal sets directory to HOME for ctrl-shift-n and custom
  shell command

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gnome-terminal/+bug/1609342/+subscriptions

-- 
desktop-bugs mailing list
desktop-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/desktop-bugs