Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • A autojump
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 158
    • Issues 158
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 54
    • Merge requests 54
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • William Ting
  • autojump
  • Merge requests
  • !365

Correct return from autojump_add_to_database in bash.

  • Review changes

  • Download
  • Email patches
  • Plain diff
Open Administrator requested to merge github/fork/leni536/master into master Jun 08, 2015
  • Overview 1
  • Commits 1
  • Pipelines 0
  • Changes 1

Created by: leni536

By default autojump_add_to_database changed the value of $? (typically to 0) so if other functions was hooked to $PROMPT_COMMAND after this function they couldn't get the correct return value of the previous interactive bash command through "$?" (example: some prompt colorizing function which depends on $?). This commit fixes this.

Note: this is not a problem if autojump is the last library sourced from .bashrc since it puts autojump at the end of $PROMPT_COMMAND. However if multiple $PROMPT_COMMAND function from different bash sources relied on being the last one it could be a problem.

Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: github/fork/leni536/master