Skip to content

stack setup --reinstall doesn't cause reinstallation #2554

@sjakobi

Description

@sjakobi
~ $ stack setup --help
...
  --[no-]reinstall         Enable/disable reinstalling GHC, even if available
                           (implies no-system-ghc)
...
~ $ stack setup
Run from outside a project, using implicit global project config
Using resolver: nightly-2016-08-25 from implicit global project's config file: /home/simon/.stack/global-project/stack.yaml
stack will use a sandboxed GHC it installed
For more information on paths, see 'stack path' and 'stack exec env'
To use this GHC and packages outside of a project, consider using:
stack ghc, stack ghci, stack runghc, or stack exec
~ $ stack setup --reinstall -v
Version 1.2.1, Git revision a77c00b92b6edfb1ffd99a3fea9fd54b9ab1c66c (dirty) (4047 commits) x86_64 hpack-0.14.1
2016-09-01 04:07:53.920464: [debug] Checking for project config at: /home/simon/stack.yaml
@(Stack/Config.hs:797:9)
2016-09-01 04:07:53.920826: [debug] Checking for project config at: /home/stack.yaml
@(Stack/Config.hs:797:9)
2016-09-01 04:07:53.921018: [debug] Checking for project config at: /stack.yaml
@(Stack/Config.hs:797:9)
2016-09-01 04:07:53.921154: [debug] No project config file found, using defaults.
@(Stack/Config.hs:819:13)
2016-09-01 04:07:53.923710: [info] Run from outside a project, using implicit global project config
@(Stack/Config.hs:432:13)
2016-09-01 04:07:53.924760: [info] Using resolver: nightly-2016-08-25 from implicit global project's config file: /home/simon/.stack/global-project/stack.yaml
@(Stack/Config.hs:446:32)
2016-09-01 04:07:53.925006: [debug] Trying to decode /home/simon/.stack/build-plan-cache/x86_64-linux/nightly-2016-08-25.cache
@(Data/Store/VersionTagged.hs:68:5)
2016-09-01 04:07:53.946823: [debug] Success decoding /home/simon/.stack/build-plan-cache/x86_64-linux/nightly-2016-08-25.cache
@(Data/Store/VersionTagged.hs:72:13)
2016-09-01 04:07:53.954226: [debug] Run process: /sbin/ldconfig -p
@(System/Process/Read.hs:277:3)
2016-09-01 04:07:53.957091: [debug] Process finished in 2 ms: /sbin/ldconfig -p
@(System/Process/Read.hs:277:3)
2016-09-01 04:07:53.958039: [debug] Did not find libtinfo.so.6 or libgmp.so.3; using standard GHC build
@(Stack/Setup.hs:503:25)
2016-09-01 04:07:53.960657: [debug] Performing a sanity check on: /home/simon/.stack/programs/x86_64-linux/ghc-8.0.1/bin/ghc
@(Stack/Setup.hs:1450:5)
2016-09-01 04:07:53.961316: [debug] Run process: /home/simon/.stack/programs/x86_64-linux/ghc-8.0.1/bin/ghc /tmp/stack-sanity-check17467/Main.hs -no-user-package-db
@(System/Process/Read.hs:277:3)
2016-09-01 04:07:54.620799: [debug] Process finished in 659 ms: /home/simon/.stack/programs/x86_64-linux/ghc-8.0.1/bin/ghc /tmp/stack-sanity-check17467/Main.hs -no-user-package-db
@(System/Process/Read.hs:277:3)
2016-09-01 04:07:54.621690: [info] stack will use a sandboxed GHC it installed
@(Stack/SetupCmd.hs:105:19)
2016-09-01 04:07:54.621794: [info] For more information on paths, see 'stack path' and 'stack exec env'
@(Stack/SetupCmd.hs:106:5)
2016-09-01 04:07:54.621900: [info] To use this GHC and packages outside of a project, consider using:
@(Stack/SetupCmd.hs:107:5)
2016-09-01 04:07:54.621991: [info] stack ghc, stack ghci, stack runghc, or stack exec
@(Stack/SetupCmd.hs:108:5)

To me --reinstall sounds like it should always cause reinstallation. I'd expect it at least to remove and restore /home/simon/.stack/programs/x86_64-linux/ghc-8.0.1 in my case.

If it should turn out that --reinstall behaves as intended, at least the help text should be improved.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions