Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

env set in my fish config prevails over what I set in the env var collection #184009

Closed
Tracked by #20822
meganrogge opened this issue Jun 1, 2023 · 5 comments · Fixed by #195416
Closed
Tracked by #20822

env set in my fish config prevails over what I set in the env var collection #184009

meganrogge opened this issue Jun 1, 2023 · 5 comments · Fixed by #195416
Assignees
Labels
api bug Issue identified by VS Code Team member as probable bug insiders-released Patch has been released in VS Code Insiders terminal-shell-fish An issue in the terminal specific to fish, including shell integration terminal-shell-integration Shell integration infrastructure, command decorations, etc. verified Verification succeeded
Milestone

Comments

@meganrogge
Copy link
Contributor

Testing #182970

	const term2 = vscode.window.createTerminal({
		name: `Ext Terminal tranisent #${NEXT_TERM_ID++}`,
		isTransient: true,
		shellPath: 'fish'
	} as any);
	const collection = context.environmentVariableCollection;
		collection.replace('FOO', 'REPLACED', { applyAtShellIntegration: true, applyAtProcessCreation: false });
		collection.append('APPENDING', 'appending', { applyAtShellIntegration: true, applyAtProcessCreation: false })
		collection.prepend('PREPENDING', 'prepending', { applyAtShellIntegration: true, applyAtProcessCreation: false });

Screenshot 2023-05-31 at 7 59 39 PM

Screenshot 2023-05-31 at 8 00 08 PM

@meganrogge meganrogge changed the title with applyAtShellIntegration:true, env set in my fish config prevails over what I set in the env var collection env set in my fish config prevails over what I set in the env var collection Jun 1, 2023
@Tyriar Tyriar added bug Issue identified by VS Code Team member as probable bug terminal-shell-integration Shell integration infrastructure, command decorations, etc. terminal-shell-fish An issue in the terminal specific to fish, including shell integration labels Jun 1, 2023
@Tyriar Tyriar added this to the June 2023 milestone Jun 1, 2023
@Tyriar Tyriar added the api label Jun 1, 2023
@Tyriar
Copy link
Member

Tyriar commented Jun 9, 2023

This is because of the same problem that caused #184191

@Tyriar Tyriar modified the milestones: June 2023, Backlog Jun 26, 2023
@karrtikr
Copy link
Contributor

@Tyriar #184191 appears to be closed now, does that mean this has been fixed?

@Tyriar
Copy link
Member

Tyriar commented Jul 11, 2023

No, this issue is about fish acting atypical in that it applies the environment before fish.config is applied. This is because of how the automatic injection works in fish via an environment variable. Still not sure how we can handle this.

@karrtikr
Copy link
Contributor

Discussed offline, maybe we could use the first pre exec hook in fish to run shell integration, instead of XDG_DATA_DIRS.

@Tyriar Tyriar modified the milestones: Backlog, August 2023 Jul 27, 2023
@Tyriar Tyriar modified the milestones: August 2023, September 2023 Aug 28, 2023
@Tyriar Tyriar modified the milestones: September 2023, Backlog Sep 25, 2023
@Tyriar Tyriar modified the milestones: Backlog, October 2023 Oct 11, 2023
Tyriar added a commit that referenced this issue Oct 11, 2023
@vscodenpa vscodenpa added unreleased Patch has not yet been released in VS Code Insiders and removed unreleased Patch has not yet been released in VS Code Insiders labels Oct 12, 2023
@vscodenpa vscodenpa added the insiders-released Patch has been released in VS Code Insiders label Oct 12, 2023
@meganrogge
Copy link
Contributor Author

Nice 👍

Image

@meganrogge meganrogge added the verified Verification succeeded label Oct 25, 2023
Alex0007 pushed a commit to Alex0007/vscode that referenced this issue Oct 26, 2023
@github-actions github-actions bot locked and limited conversation to collaborators Nov 26, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
api bug Issue identified by VS Code Team member as probable bug insiders-released Patch has been released in VS Code Insiders terminal-shell-fish An issue in the terminal specific to fish, including shell integration terminal-shell-integration Shell integration infrastructure, command decorations, etc. verified Verification succeeded
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants