Posts

Избранное сообщение

What's the better, safe, easy to use and performant: wget, scoop, chocolately

Image
What's the belter, safe, easy to use and performant: wget, scoop, chocolately When comparing these tools, we first need to correct a small piece of terminology: wget is not a package manager —it is a command-line utility used solely for downloading individual files from the internet. Assuming you meant winget (Microsoft's official Windows Package Manager) alongside Scoop and Chocolatey , here is how they stack up. For most modern Windows users and developers, Winget is the overall best, easiest, and safest option for general applications , while Scoop is the highest-performing and cleanest choice specifically for developer tools . Direct Comparison Feature Winget (Microsoft) Scoop Chocolatey Best For Everyday apps, native Windows software, and zero-setup use Command-line utilities, developer tools, and clean installs Enterprise environments, massive legacy app support Ease of Use Highest (Built straight into Windows 10/11) High (Simple syntax, no admin popups) Moderate (...

How to revert changes to only specific file(s)?

How to revert changes to only specific file(s)?  To revert changes to a specific file in Git, use git restore <file> for uncommitted changes or git checkout <commit> -- <file > to pull an older version from history. The correct command depends on whether your changes are saved, staged, or already committed.   Uncommitted Changes Discard local edits in the working directory: git restore <file-path> Unstage a file while keeping your local edits: git restore --staged <file-path> Discard changes in both staged and working directories: git restore <file-path>   Revert a file to how it looked in a past commit: git checkout <commit-hash> -- <file-path> Pull a specific file from another branch: git checkout <branch-name> -- <file-path> To revert a specific file that has already been committed, use git checkout or git restore with a specific commit hash. Overwrite the file and prepare a new commit This method changes ...

Npm i and npm ci , what difference?

Npm i and npm ci , what difference? npm install / npm i - installation which can rewrite package.json and package-lock.json npm ci - clean install which removes node_modules and use package-lock json for installing and do not rewrite them package-lock.json and package.json npm install Installs a package and all its dependencies. Dependencies are driven by npm-shrinkwrap.json and package-lock.json (in that order). without arguments : installs dependencies of a local module. Can install global packages. Will install any missing dependencies in node_modules . It may write to package.json or package-lock.json . When used with an argument ( npm i packagename ) it may write to package.json to add or update the dependency. when used without arguments, ( npm i ) it may write to package-lock.json to lock down the version of some dependencies if they are not already in this file. npm ci Requires at least npm v5.7.1 . Requires package-lock.json or npm-shrinkwrap.json to be present. Thro...