-
Notifications
You must be signed in to change notification settings - Fork 280
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
getCurrentDirectory问题 #10
Comments
刚刚看到这个,,,所以这个没有好办法解决么。。。。。 |
添加getCurrentDirectory方法是为了解决直接运行二进制文件无法找到view的问题,正常情况下返回“”就行 |
使用GoLand开发的话,修改下Working directory路径为当前项目文件,就解决了这个问题。。。。 |
` ` |
Windows10
我在GoLand IDE中调试和编译。发现用这个方法获得的路径是X:\xxxx\xxx\AppData\Local\Temp路径. 然后去找views的时候就找不到,报错了。
如果使用go build main.go 。然后直接run, 则路径没有问题。
这是什么原因呢,应该怎么解决
The text was updated successfully, but these errors were encountered: