mirror of
https://github.com/crunchy-labs/crunchy-cli.git
synced 2026-01-21 20:22:01 -06:00
Merge branch 'crunchy-labs:master' into master
This commit is contained in:
commit
4eef071b83
1 changed files with 2 additions and 0 deletions
|
|
@ -18,6 +18,8 @@ pub struct Login {
|
||||||
impl Execute for Login {
|
impl Execute for Login {
|
||||||
async fn execute(self, ctx: Context) -> Result<()> {
|
async fn execute(self, ctx: Context) -> Result<()> {
|
||||||
if let Some(login_file_path) = login_file_path() {
|
if let Some(login_file_path) = login_file_path() {
|
||||||
|
fs::create_dir_all(login_file_path.parent().unwrap())?;
|
||||||
|
|
||||||
match ctx.crunchy.session_token().await {
|
match ctx.crunchy.session_token().await {
|
||||||
SessionToken::RefreshToken(refresh_token) => Ok(fs::write(
|
SessionToken::RefreshToken(refresh_token) => Ok(fs::write(
|
||||||
login_file_path,
|
login_file_path,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue