My Personal Environment's Configuration and Setup
-- Domin
-
Obtain current repository by cloning it, or what is more likely at fresh environment, by downloading ZIP archive and extracting it. Then place that
EnvConfig
within desiredRepos
Home Directory - e.g.~/Repos
orD:\Repos
. -
Using
!elevate-session.ps1
script, start PowerShell session (PSSession
) elevated to the Administrator Role. -
Set necessary execution policy for the whole machine:
Set-ExecutionPolicy -Scope LocalMachine -ExecutionPolicy RemoteSigned -Confirm
-
Install Chocolatey: a package manager for Windows, using elevated
PSSession
:((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1')) ` | Invoke-Expression
-
Execute prepare script:
> .\Choco\!prepare.ps1
- Optional script's parameter:
-PkgLevel (core|tools|dev|full)
- Default value is assumed to be:
-PkgLevel full
- Each value encompass all previous levels.
- Optional script's parameter:
-
That script requires Chocolatey and have to be executed from
PSSession
elevated to Admin. -
What does that script do?
- Will turn on
choco
's feature: Use Remembered Arguments For Upgrades. - Will install every defined applications according to selected packages level.
- Some packages or their dependencies may require reboot after installation.
- Will turn on
-
Execute prepare script:
> .\Shells\!prepare.ps1
- Script provides a single switch:
-PwshAllUsers
.
- Script provides a single switch:
-
That script have to be executed from
PSSession
elevated to Admin from target user.- This requirement could be lifted, when creating
SymbolicLink
will be available to normal users.
- This requirement could be lifted, when creating
-
What does that script do?
- Will make symbolic-links at Home (
~/
) directory of current user with Bash and Git configuration files:.bash_profile
+.bashrc
, and.gitconfig
. - Will install pwsh-modules:
posh-git
andoh-my-posh
, which are utilized byProfile.ps1
for more user friendly UX of terminal. - Symbolic-link will also be created for profile-file for PowerShell at
~/Documents/PowerShell/Profile.ps1
- no profile for old but yet default PowerShell 5. - When
-PwshAllUsers
is provided, the Pwsh is set up with Profile and Modules for All Users underC:/Program Files/PowerShell
.
- Will make symbolic-links at Home (
-
Execute prepare script:
> .\System\!prepare.ps1
- Script has a few switches. When any of then is present, only related changes will be executed. Script by default executes all of them.
- Available switches:
-AssocTxtfile
,-CtxMenuCleanUp
,-ProcessExpSchedule
,-WinExplorerPrepare
,-DittoConfigSetup
,-FluxConfigSetup
,-HWiNFO64ConfigSetup
,-UpdateScriptInstall
.
-
That script have to be executed from
PSSession
elevated to Admin from target user. -
What does that script do?
-AssocTxtfile
: Will setup every defined files' extensions to be treated as Text-Based files by Windows Explorer.-CtxMenuCleanUp
: Will clean up context menu of folders from unnecessary defined entries.-WinExplorerPrepare
: Will fix Explorer's display configuration and organize Quick Access with a few handy folders. This script expect that there is a parent directory calledRepos
and one of theirs sibling is calledPersonal
- both of them will be pinned.-ProcessExpSchedule
: Will schedule Process Explorer by Mark Russinovich to start on Logon.-DittoConfigSetup
: Will load into Register non-default-personal Ditto's configuration.-FluxConfigSetup
: Will import Register-based f.lux's configuration adjusted for Domin's lifestyle.-HWiNFO64ConfigSetup
: Will configure HWiNFO64 to sense CPU and GPU temperatures of CGL.-UpdateScriptInstall
: Will linkupdate-system.bat
intoPATH
available directory, so Admin can request and execute whole System update.
-
Execute prepare script:
> .\VSCode\!prepare.ps1
- Optional multi-value parameter:
-Extensions
: defines which extensions groups will be installed. Available values:core
,tools
,dev
,webdev
,work
,extra
- whereall
matches to every extension and multiple values are separated by comma. - There are two additional switches:
SkipExtra
andSkipWork
, which excludes matched group even explicitly requested. - By default
-Extensions
assumesall
group, for ease of use.
- Optional multi-value parameter:
-
That script requires installed VS Code, which could be download from Microsoft.
-
What does that script do?
- Will link configuration files (
settings.json
,keybindings.json
) at User Code's profile directory. - Will install every defined extensions for VS Code according to selected extensions-group.
- Will link configuration files (
- Extensions and configuration presented in file:
VSCommunity.md
. - Download and install it from Microsoft (Community version).
- Use any Ergodox compatible devices and load
recent.hex
layout. - More details one can find at:
Keyboard/README.md
.
-
Chapters presented above are set in the proposed order of execution of steps for configuration setup.
-
Initial placement of
EnvConfigs
repository is very important and should be under desiredRepos
:- Many prepare script (i.e.
!prepare.ps1
) will make symbolic-links into files located here. - The prepare script of
System
will pin as favorites and decorate a parent directory asRepos
. - Every prepare script should be run from this repository's root directory via PowerShell.
- Many prepare script (i.e.
-
It is required to have PowerShell in version greater then
3.0
. Fortunately, Windows 10 currently comes with version5.1
- to check it, one can type:$PSVersionTable.PSVersion
within runningPSSession
. -
Almost all scripts expect to be run within PowerShell session with elevated permissions to the Administrator Role. To obtain elevated PowerShell console, just execute:
PowerShell.exe -NoProfile -File ".\!elevate-session.ps1"
-
While preparing fresh environment, current repository was probably just downloaded as ZIP without any Git Tracking ability - as there were no
git
available at beginning of setup.- It is not recommended to clone it again in desired place, as it should be already in expected
Repos
Home Directory. - It is strongly encouraged to restore Git support within current directory - to easily track future configuration changes.
- It is not recommended to clone it again in desired place, as it should be already in expected
-
To reestablish Git support within current repository, one should use favorite terminal under their own user account and call in order:
git init --initial-branch=main git remote add origin https://github.com/DominikJaniec/EnvConfigs.git git fetch git reset origin/main --mixed git branch --set-upstream-to=origin/main git status