-
Notifications
You must be signed in to change notification settings - Fork 847
Closed
Description
Steps to reproduce
- Set a path with spaces in the
local-program-pathof%STACK_ROOT%\config.yaml
local-programs-path: D:\bin\s t a c k
- Create simple file script
example.hs:
#!/usr/bin/env stack
{- stack
runghc
--resolver=lts-14.1
-}
main = putStrLn "Hello"- Run command
stack example.hs.
Expected
Show the same warning as you run stack <command>:
PS D:\dev\ws\haskell\stack-test> stack build
Stack's 'programs' path contains a space character and has no alternative short ('8 dot 3') name. This will cause problems with packages that use the GNU project's 'configure' shell script. Use the 'local-programs-path' configuation option to specify an alternative path. The current 'shortest' path is: D:\bin\s t a c k\Actual
It shows nothing about the possible issues caused by that configuration.
The original issue was in haskell-ide-engine: a user with spaces in %USER_PROFILE% (very common in windows versions below 10 or win 10 migrated from older one) and the default local-programs-path got an error running the script to install hie executable:
install.hs: C:\Users\Arthur: createProcess: does not exist (No such file or directory)
Setting local-programs-path without spaces fixed the error.
(As a side note i found the warning message a little bit weird: '8 dot 3'? The current 'shortest' path is: D:\bin\s t a c k\? and has a typo: configuation)
Stack version
$ stack --version
Version 2.1.3, Git revision 0fa51b9925decd937e4a993ad90cb686f88fa282 (7739 commits) x86_64 hpack-0.31.2
Method of installation
- Official binary, downloaded from stackage.org or fpcomplete's package repository