Make ansible-vault view not write plaintext to a tempfile #12572

Merged
merged 1 commit into from Sep 30, 2015

Conversation

Projects
None yet
3 participants
@amenonsen
Contributor

amenonsen commented Sep 30, 2015

…when it can just feed the PAGER on stdin instead.

@bcoca

This comment has been minimized.

Show comment
Hide comment
@bcoca

bcoca Sep 30, 2015

Member

nice

Member

bcoca commented Sep 30, 2015

nice

@bcoca

This comment has been minimized.

Show comment
Hide comment
@bcoca

bcoca Sep 30, 2015

Member

you could also just feed self.pager() function in the cli

Member

bcoca commented Sep 30, 2015

you could also just feed self.pager() function in the cli

Make «ansible-vault view» not write plaintext to a tempfile
CLI already provides a pager() method that feeds $PAGER on stdin, so we
just feed that the plaintext from the vault file. We can also eliminate
the redundant and now-unused shell_pager_command method in VaultEditor.
@amenonsen

This comment has been minimized.

Show comment
Hide comment
@amenonsen

amenonsen Sep 30, 2015

Contributor

@bcoca thanks for the suggestion, I didn't notice CLI's pager() method. I've pushed a revised version along those lines (and tested it with single/multiple files, with more/less/nonexistent-pager and so on).

Contributor

amenonsen commented Sep 30, 2015

@bcoca thanks for the suggestion, I didn't notice CLI's pager() method. I've pushed a revised version along those lines (and tested it with single/multiple files, with more/less/nonexistent-pager and so on).

@bcoca

This comment has been minimized.

Show comment
Hide comment
@bcoca

bcoca Sep 30, 2015

Member

he, even nicer that we get to remove soo many lines

Member

bcoca commented Sep 30, 2015

he, even nicer that we get to remove soo many lines

bcoca added a commit that referenced this pull request Sep 30, 2015

Merge pull request #12572 from amenonsen/vault-pager
Make ansible-vault view not write plaintext to a tempfile

@bcoca bcoca merged commit 6d8abe8 into ansible:devel Sep 30, 2015

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details

@amenonsen amenonsen deleted the amenonsen:vault-pager branch Dec 11, 2015

@ansibot ansibot added feature and removed feature_pull_request labels Mar 4, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment