JanDeDobbeleer / prompt

Quick and easy prompt setup for PowerShell

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Introduction

This repository holds the files I use for initializing a new machine and my PowerShell prompt.

prompt

The theme for oh-my-posh can be found in the oh-my-config.json file.

This file is modified from Scott Hanselman's Gist here: shanselman/ohmyposhv3-v2.json

End result in current version:

image

Profile Setup

Required Modules

I prefer to store modules under the AllUsers scope so those files are not constantly sync'd by OneDrive. The init.ps1 script will handle a few things:

  1. Installing requiredmodules
  2. Create an initial Secret vault called myCredentials if it does not already exists

Run the following command in an elevated PowerShell session

.\init.ps1

Modify PowerShell Profile

The PSReadLine customizations were modified from Scott Hanselman's profile Gist: shanselman/Microsoft.PowerShell_profile.ps1

After running the init process above, open your PowerShell profile (e.g., notepad $profile), and add the line below.

Adjust the path based on where you cloned this repository to your local machine

. c:\git\prompt\ps-profile.ps1

About

Quick and easy prompt setup for PowerShell


Languages

Language:PowerShell 100.0%