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

CRLF should transform to LF in Ubuntu WSL #280

Closed
yicixin opened this issue Mar 27, 2024 · 1 comment
Closed

CRLF should transform to LF in Ubuntu WSL #280

yicixin opened this issue Mar 27, 2024 · 1 comment
Labels
invalid This doesn't seem right

Comments

@yicixin
Copy link

yicixin commented Mar 27, 2024

Describe the bug

what I inserted to .zshrc:

# Download Znap, if it's not there yet.
[[ -r ~/znap_repos/znap/znap.zsh ]] ||
    git clone --depth 1 -- \
        https://github.com/marlonrichert/zsh-snap.git ~/znap_repos/znap
source ~/znap_repos/znap/znap.zsh  # Start Znap

then I execute source .zshrc, I got:

source .zshrc
Cloning into '/home/yicixin/znap_repos/znap'...
remote: Enumerating objects: 44, done.
remote: Counting objects: 100% (44/44), done.
remote: Compressing objects: 100% (40/40), done.
remote: Total 44 (delta 0), reused 19 (delta 0), pack-reused 0
Unpacking objects: 100% (44/44), 21.33 KiB | 2.13 MiB/s, done.
/home/yicixin/znap_repos/znap/znap.zsh:2: invalid module name `zsh/param/private^M'

Environmental information

❯ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 20.04.6 LTS
Release:        20.04
Codename:       focal

❯ zsh --version                             
zsh 5.8 (x86_64-ubuntu-linux-gnu)
@yicixin yicixin added the bug Something isn't working label Mar 27, 2024
@marlonrichert marlonrichert added invalid This doesn't seem right and removed bug Something isn't working labels Jun 17, 2024
@vladislav-boshnakov
Copy link

Hello @yicixin I had the same problem while running the install under WSL Ubuntu.
It's a problem with git line endings. Change your global git config to remove the autodetect of the line ending
like so:
git config --global core.autocrlf false
then just delete the folder you installed znap in and rerun our shell or reinstall znap
That should fix the issue :)

@yicixin yicixin closed this as completed Jul 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
invalid This doesn't seem right
Projects
None yet
Development

No branches or pull requests

3 participants