Skip to content

Commit

Permalink
Bug 989 (#15)
Browse files Browse the repository at this point in the history
* Fixed id-token cmd to run mamba

* making mamba running in uid.go

* removing unnecessary codes

---------

Co-authored-by: Xiaomeng Ye <yebyyy@lawn-128-61-121-187.lawn.gatech.edu>
  • Loading branch information
yebyyy and Xiaomeng Ye authored Jan 10, 2024
1 parent 552ba26 commit 6dca7e3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion cmd/backend/id_token/id_token.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@ var IdTokenCmd = &cobra.Command{
Long: `gets a user's id token by email from the backend`,
Args: cobra.ExactArgs(1),
Run: func(cmd *cobra.Command, args []string) {
backend.ExecBashCmd("poetry", "run", "python", "cli.py", "get-id-token", args[0])
env_name := cmd.Flag("env-name").Value.String()
backend.ExecBashCmd("mamba", "run", "-n", env_name, "poetry", "run", "python", "cli.py", "get-id-token", args[0])
},
}

Expand Down
3 changes: 2 additions & 1 deletion cmd/backend/uid/uid.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@ var UidCmd = &cobra.Command{
Long: `gets a user's uid by email from the backend`,
Args: cobra.ExactArgs(1),
Run: func(cmd *cobra.Command, args []string) {
backend.ExecBashCmd("poetry", "run", "python", "cli.py", "get-uid", args[0])
env_name := cmd.Flag("env-name").Value.String()
backend.ExecBashCmd("mamba", "run", "-n", env_name, "poetry", "run", "python", "cli.py", "get-uid", args[0])
},
}

Expand Down

0 comments on commit 6dca7e3

Please sign in to comment.