windows_env

import and export windows environment to and from file

windows_env

Windows Environment Variable Manager

This Crystal script provides a command-line utility for exporting and importing environment variables in Windows, with support for both user and system-level environments.

Features

  • Export environment variables to a YAML file
  • Import environment variables from a YAML file
  • Support for both user and system-level environments
  • Command-line interface with flexible options

Functionality

The script allows you to:

  1. Export current environment variables to a YAML file
  2. Import environment variables from a YAML file
  3. Work with both user and system-level environments

Usage

Command-line Options:

  • -a, --action ACTION: Specify action (export or import)
  • -s, --scope SCOPE: Specify scope (user or system)
  • -f, --file FILE: Specify filename for export/import
  • -h, --help: Show help information

Examples

Export User Environment

crystal windows_env.cr -a export -s user -f user_env.yml

Import System Environment

crystal windows_env.cr -a import -s system -f system_env.yml

Installation

TODO: Write installation instructions here

Usage

windows_env.cr  [options]

Requirements

  • Crystal programming language
  • Windows operating system
  • PowerShell (for system environment interactions)

Installation

  1. Ensure Crystal is installed
  2. Clone the repository
  3. Run the script directly with Crystal

Limitations

  • Requires administrative privileges for system-level environment modifications
  • Currently designed for Windows environments

Contributing

  1. Fork it (https://github.com/dsisnero/windows_env/fork)
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create a new Pull Request

Contributors

TODO

  • Add error handling
  • Implement more robust environment variable management
  • Add support for more complex environment scenarios

Notes

The script uses PowerShell commands to interact with Windows registry for system environment variables, making it Windows-specific.

Version

Current version: 0.1.0

Repository

windows_env

Owner
Statistic
  • 0
  • 0
  • 0
  • 0
  • 0
  • 4 days ago
  • May 6, 2025
License

MIT License

Links
Synced at

Fri, 09 May 2025 13:33:45 GMT

Languages