Skip to content
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

zeal.ini is installed as a folder instead of a file #1481

Closed
zhaocai opened this issue Dec 1, 2018 · 4 comments · Fixed by #1852
Closed

zeal.ini is installed as a folder instead of a file #1481

zhaocai opened this issue Dec 1, 2018 · 4 comments · Fixed by #1852

Comments

@zhaocai
Copy link

zhaocai commented Dec 1, 2018

https://github.com/lukesampson/scoop-extras/blob/ae9d03c0ce987e3741bd12c2558fe5ec1430d70d/zeal.json#L19

zeal.ini is a config file. No settings can be saved if it is a folder.

@Ash258
Copy link
Contributor

Ash258 commented Dec 1, 2018

@Ash258
Copy link
Contributor

Ash258 commented Dec 1, 2018

If you want temporary solution:

  1. Uninstall Zeal: scoop unisntall zeal --purge
  2. Go to $env:SCOOP\persist
  3. Create folder zeal
  4. Create zeal.ini file inside zeal folder
  5. scoop install zeal

It should correctly assume file instead of folder

@rasa
Copy link
Member

rasa commented Dec 7, 2018

Closing as a dup of ScoopInstaller/Scoop#2779

@studoot
Copy link
Contributor

studoot commented Mar 12, 2019

It seems to me that ScoopInstaller/Scoop#2779 doesn't actually fix the underlying problem, which is that zeal.ini is created as a driectory, not as a file. Is some change required in the zeal recipe to tell scoop that zeal.ini is a linked file, not a linked directory?

Looking in the text of ScoopInstaller/Scoop#2779, I see the following text:

 "pre_install": [
        "if (!(test-path \"$dir\\dummy.txt\")) { new-item -force \"$dir\\dummy.txt\" -itemtype file | out-null }",
        "if (!(test-path \"$dir\\dummydir\")) { new-item \"$dir\\dummydir\" -itemtype directory | out-null }",
        "if (!(test-path \"$dir\\subdir\")) { new-item \"$dir\\subdir\" -itemtype directory | out-null }",
        "if (!(test-path \"$dir\\subdir\\subdummydir\")) { new-item \"$dir\\subdir\\subdummydir\" -itemtype directory | out-null }",
        "if (!(test-path \"$dir\\subdir\\subdummy.txt\")) { new-item -force \"$dir\\subdir\\subdummy.txt\" -itemtype file | out-null }",
    ],
    "persist": [
        "dummy.txt",
        "dummydir",
        "subdir\\subdummydir",
        "subdir\\subdummy.txt"
    ]

which implies that the zeal recipe needs a pre-install step to create the zeal.ini file and cache and docsets directories? Like this:

 "pre_install": [
        "if (!(test-path \"$dir\\zeal.ini\")) { new-item -force \"$dir\\zeal.ini\" -itemtype file | out-null }",
    ],
    "persist": [
        "zeal.ini",
        "cache",
        "docsets",
    ]

If that's the case, I'll do a pull request for Zeal to fix this...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants