Skip to content

Conversation

@floam
Copy link
Contributor

@floam floam commented Dec 8, 2021

This PR has two minor changes for FishCompletionsGenerator.swift.

The first is related to the name of the fish function created that's used to determine whether to show completions or not, depending on the commandline entered thus far. Functions beginning with __fish really ought only be things internal to fish that are included with the shell. So prefix the function _swift instead.

Secondly, set --local cmd instead of set cmd - this ensures running the function does not accidentally clobber a global or universal variable.

__fish_* should not be used by external projects.
set -l cmd in case user has a global or universal `cmd` defined.
@rauhul
Copy link
Contributor

rauhul commented Dec 8, 2021

@swift-ci please test

@floam
Copy link
Contributor Author

floam commented Dec 8, 2021

There was a test failure; I believe I force-pushed the correction.

@rauhul
Copy link
Contributor

rauhul commented Dec 8, 2021

@swift-ci please test

@floam
Copy link
Contributor Author

floam commented Dec 8, 2021

Okay, I'm finally running swift test myself now, and there are now zero failures. I'm just an old chunk of coal.

@rauhul
Copy link
Contributor

rauhul commented Dec 8, 2021

@swift-ci please test

@natecook1000
Copy link
Member

This is great, thanks @floam! 👏🏻

@natecook1000 natecook1000 merged commit 7e04f56 into apple:main Dec 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants