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

Error when I install #7

Closed
Sorenwise opened this issue Oct 31, 2022 · 13 comments
Closed

Error when I install #7

Sorenwise opened this issue Oct 31, 2022 · 13 comments

Comments

@Sorenwise
Copy link

I get this error when I try to install your script I think its a script.

iex : At line:198 char:17

  •         Sign up
    
  •             ~
    

The ampersand (&) character is not allowed. The & operator is reserved for future use; wrap an ampersand in double
quotation marks ("&") to pass it as part of a string.
At line:203 char:209

  • ... k Button--medium Button d-lg-none color-fg-inherit p-1"> <span cla ...
  •                                                             ~
    

The '<' operator is reserved for future use.
At line:412 char:13

  •   CI/CD &amp; Automation
    
  •         ~
    

The ampersand (&) character is not allowed. The & operator is reserved for future use; wrap an ampersand in double
quotation marks ("&") to pass it as part of a string.
At line:1684 char:126

  • ... js-jump-to-line-field" type="text" placeholder="Jump to line…" ...
  •                                                             ~
    

The ampersand (&) character is not allowed. The & operator is reserved for future use; wrap an ampersand in double
quotation marks ("&") to pass it as part of a string.
At line:1684 char:148

  • ... pe="text" placeholder="Jump to line…" aria-label="Jump to line ...
  •                                                          ~~~~
    

Unexpected token 'Jump' in expression or statement.
At line:1726 char:153

  • ... thub-terms-of-service" data-analytics-event="{"category":&q ...
  •                                                             ~
    

The ampersand (&) character is not allowed. The & operator is reserved for future use; wrap an ampersand in double
quotation marks ("&") to pass it as part of a string.
At line:1726 char:160

  • ... rms-of-service" data-analytics-event="{"category":"Foo ...
  •                                                             ~
    

The ampersand (&) character is not allowed. The & operator is reserved for future use; wrap an ampersand in double
quotation marks ("&") to pass it as part of a string.
At line:1726 char:172

  • ... ce" data-analytics-event="{"category":"Footer",&q ...
  •                                                             ~
    

The ampersand (&) character is not allowed. The & operator is reserved for future use; wrap an ampersand in double
quotation marks ("&") to pass it as part of a string.
At line:1726 char:179

  • ... ta-analytics-event="{"category":"Footer","ac ...
  •                                                              ~
    

Missing expression after unary operator ','.
At line:1726 char:179

  • ... a-analytics-event="{"category":"Footer","act ...
  •                                                             ~
    

Unexpected token '&' in expression or statement.
Not all parse errors were reported. Correct the reported errors and try again.
At line:1 char:82

  • ... thub.com/ChrisTitusTech/powershell-profile/blob/main/setup.ps1" | iex
  •                                                                   ~~~
    
    • CategoryInfo : ParserError: (:) [Invoke-Expression], ParseException
    • FullyQualifiedErrorId : AmpersandNotAllowed,Microsoft.PowerShell.Commands.InvokeExpressionCommand
@Sorenwise
Copy link
Author

ok I fixed it by doing a manual install

but now I am getting this error

"oh-my-posh : The term 'oh-my-posh' is not recognized as the name of a cmdlet, function, script file, or operable
program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
At E:\Users\user\Documents\WindowsPowerShell\Microsoft.PowerShell_profile.ps1:210 char:1

  • oh-my-posh --init --shell pwsh --config ~/jandedobbeleer.omp.json | I ...
  •   + CategoryInfo          : ObjectNotFound: (oh-my-posh:String) [], CommandNotFoundException
      + FullyQualifiedErrorId : CommandNotFoundException"
    
    

What is jandedobbeleer?

@TheyCallMeZ
Copy link
Contributor

@Sorenwise you need to run the command to install Oh-my-posh which was created by jandedobbeleer.
You will need to run the following from Chris's setup script or install from the ohmyposh website

# OMP Install
#
winget install -e --accept-source-agreements --accept-package-agreements JanDeDobbeleer.OhMyPosh

# Font Install
Invoke-RestMethod https://github.com/ryanoasis/nerd-fonts/releases/download/v2.1.0/CascadiaCode.zip?WT.mc_id=-blog-scottha -o cove.zip

@Sorenwise
Copy link
Author

Sorenwise commented Nov 1, 2022

@Sorenwise you need to run the command to install Oh-my-posh which was created by jandedobbeleer. You will need to run the following from Chris's setup script or install from the ohmyposh website

# OMP Install
#
winget install -e --accept-source-agreements --accept-package-agreements JanDeDobbeleer.OhMyPosh

# Font Install
Invoke-RestMethod https://github.com/ryanoasis/nerd-fonts/releases/download/v2.1.0/CascadiaCode.zip?WT.mc_id=-blog-scottha -o cove.zip

@TheyCallMeZ Ok I did what you said and I got this:

https://gyazo.com/3f84c1a93f70bff19d97f97ccc80dea0

@TheyCallMeZ
Copy link
Contributor

@Sorenwise looks like you need to install a font, either use the installer that's built into oh my posh to pick and install fonts, https://ohmyposh.dev/docs/installation/fonts

after that you will need to go to the properties for your powershell window and set the font that you installed there to see the icons.

@Sorenwise
Copy link
Author

@TheyCallMeZ Yes I saw that in the directions at the end of the install file and I did go and manually install nerd fonts and I selected Cascadia which is the one CTT picked I think. But the icons are still messed up :(.

@TheyCallMeZ
Copy link
Contributor

@Sorenwise are you opening in windows terminal or direct powershell window?

For the former you need to select the nerd font in settings for powershell in terminal.

For the latter you need to go to the properties for that window, pick your font and save the settings as default.

@Sorenwise
Copy link
Author

Sorenwise commented Nov 1, 2022

@TheyCallMeZ I am just opening direct powershell just to check I tried the windows terminal but that doesn't have anything changed on it, also as admin.

Does it matter that I installed all the Cascadia fonts so like I have 10 different options? cause I dled the pack from nerd fonts directly.

@TheyCallMeZ
Copy link
Contributor

@Sorenwise
You can install as many of the fonts as you like, you just need to set that as your terminal font.
I believe the font names typically have NF in the name.

In the Terminal app, click on the down arrow and select "Settings"
image

Click on the Windows Powershell option under Profiles, scroll down and click on Appearance
image

Then Select your font from the font face dropdown
image

Save and you should be good.

With a direct powershell window
right click on the title bar, click on "Defaults", Select the Font Tab
Select one of the Nerd Fonts you installed from the list and click Ok.

@Sorenwise
Copy link
Author

Sorenwise commented Nov 2, 2022

@TheyCallMeZ Well I went into the defaults as you said and nothing I put Cascadia code and it didn't help.
Still have the same messed up window. I even updated powershell to 7.2.7 cause I was on 7.2.6.
I have noticed that some programs dont want to work cause I am in windows 1903, could that be the problem?

@TheyCallMeZ
Copy link
Contributor

@Sorenwise I installed the "Cascadia Code" font, and can confirm it does not have the symbols, I believe "CaskaydiaCove NF Mono" is installed along with it and can confirm it does show the symbols. I'm Partial to Hack as far as font choice.

Looking at the NerdFonts website (https://www.nerdfonts.com/ || https://www.nerdfonts.com/font-downloads) it seems "Cascadia Code" has the nerdfont name as mentioned above Caskaydia Cove Nerd Font
image

@Sorenwise
Copy link
Author

Sorenwise commented Nov 2, 2022

@TheyCallMeZ Well it finally worked with the Hack font but I tried the mono font and it didn't work for me. Which is weird cause I'm pretty sure I saw CTT put the Cascadia code one in the vid. Well anyway thanks for all the help resolving this and I do like how the hack font looks.

I wonder if a reinstall of the fonts would work but its working now I don't want to break it.

@TheyCallMeZ
Copy link
Contributor

@Sorenwise Nerdfonts can be weird at times. You can try downloading from the nerdfonts website and see if that version works but outside of that I'm out of ideas. Glad you like the Hack font!

@Sorenwise
Copy link
Author

Sorenwise commented Nov 3, 2022

@TheyCallMeZ I did DL from their website, I suppose maybe Id get a different result if I had run this command you told me too:

Font Install

Invoke-RestMethod https://github.com/ryanoasis/nerd-fonts/releases/download/v2.1.0/CascadiaCode.zip?WT.mc_id=-blog-scottha -o cove.zip

only thing with that is that I had already gone with the website and dled from them. I didn't know how to uninstall their fonts and use the ones from this command.

Just wanted to let you know.

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

No branches or pull requests

2 participants