Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitde6f86b

Browse files
authored
fix: ensure config dir exists before reading tunnel config (#2259)
1 parentec0bb7b commitde6f86b

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

‎coderd/devtunnel/tunnel.go

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,13 @@ func cfgPath() (string, error) {
177177
return"",xerrors.Errorf("get user config dir: %w",err)
178178
}
179179

180-
returnfilepath.Join(cfgDir,"coderv2","devtunnel"),nil
180+
cfgDir=filepath.Join(cfgDir,"coderv2")
181+
err=os.MkdirAll(cfgDir,0750)
182+
iferr!=nil {
183+
return"",xerrors.Errorf("mkdirall config dir %q: %w",cfgDir,err)
184+
}
185+
186+
returnfilepath.Join(cfgDir,"devtunnel"),nil
181187
}
182188

183189
funcreadOrGenerateConfig() (Config,error) {

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp