Skip to content

Commit

Permalink
Merge pull request #3 from ieedan/extension-work
Browse files Browse the repository at this point in the history
VS Code Extension + `vnv check` command
  • Loading branch information
ieedan authored Mar 22, 2024
2 parents 06377eb + bce69f1 commit b8c6020
Show file tree
Hide file tree
Showing 30 changed files with 1,101 additions and 126 deletions.
16 changes: 0 additions & 16 deletions .env
Original file line number Diff line number Diff line change
@@ -1,16 +0,0 @@
@startsWith("https://")
# Must be min 10 for name of domain and domain postfix Ex: (https://d.t)
@min(10)
ALLOWED_ORIGINS=["https://github.com", "https://aidanbleser.com"]
@min(1000)
@public
POLLING_INTERVAL=5000
@min(1024)
@max(49151)
@public
PORT=3000
@min(1)
API_KEY="g74Ed6Z6txrEiGX9rSybQxWfVCFDfvAvhuOBrZvsTjfuGNrNt1jyjHfhQPSdzNh5kf6juBsGfRhjFpyfJEl8L2pw39DCs2A2yJKLfWht6sY7HCalLNpDNWcHbWip8Jpc"
# IP Address regex thanks ChatGPT
@matches("^(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)$")
ALLOWED_IPS=["172.16.100.10", "192.168.1.1"]
4 changes: 4 additions & 0 deletions .github/workflows/continuous-integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,7 @@ jobs:
run: cargo build --verbose
- name: Run tests
run: cargo test --verbose
# This should not be done normally because you should not be committing your environment variables to git
# This is to make sure the binary is working and to make sure that the example file is valid syntax
- name: Check .vnv
run: ./target/debug/vnv check
19 changes: 19 additions & 0 deletions .vnv
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# This is an example of how you might use valid-env
# If you are contributing to valid-env this is a great way to test things out

@startsWith("https://")
# Must be min 10 for name of domain and domain postfix Ex: (https://d.t)
@min(10)
ALLOWED_ORIGINS=["https://github.com", "https://aidanbleser.com"]
@min(1000)
@public
POLLING_INTERVAL=5000
@min(1024)
@max(49151)
@public
PORT=3000
@min(1)
API_KEY="g74Ed6Z6txrEiGX9rSybQxWfVCFDfvAvhuOBrZvsTjfuGNrNt1jyjHfhQPSdzNh5kf6juBsGfRhjFpyfJEl8L2pw39DCs2A2yJKLfWht6sY7HCalLNpDNWcHbWip8Jpc"
# IP Address regex thanks ChatGPT
@matches("^(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)$")
ALLOWED_IPS=["172.16.100.10", "192.168.1.1"]
301 changes: 299 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 5 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
[package]
name = "valid-env"
version = "0.1.0"
name = "vnv"
version = "0.0.1"
edition = "2021"

# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[dependencies]
regex = "^1.10.3"
clap = { version = "4.5.3", features = ["derive"] }
regex = "^1.10.3"
colored = "2.0"
Loading

0 comments on commit b8c6020

Please sign in to comment.