Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Request: t3-env CLI #97

Open
FredBuild opened this issue Jul 2, 2023 · 10 comments · May be fixed by #123
Open

Feature Request: t3-env CLI #97

FredBuild opened this issue Jul 2, 2023 · 10 comments · May be fixed by #123
Labels
PRs Accepted Feel free to pick this up and make a PR

Comments

@FredBuild
Copy link

t3-env is great for managing environment variables.
However, there's a gap when it comes to command-line operations like drizzle-kit db:push.

Currently, we use dotenv-cli to load environment variables:

$ dotenv -- drizzle-kit push:mysql

This method lacks a safety check for the loaded variables.

If we created a CLI for t3-env, it could safely load, transform, and verify these variables:

$ t3-env -- drizzle-kit push:mysql
# Loads and transforms environment variables
# Throw errors if there's an issue
# If no issues, execute the command
@chungweileong94
Copy link
Contributor

That can be really useful!
As of now, you can actually use both dotenv & t3-env in drizzle.config.ts as a workaround.

@mgrithm
Copy link

mgrithm commented Jul 18, 2023

Can i implement it in rust? @chungweileong94

@chungweileong94
Copy link
Contributor

Can i implement it in rust?

I don't have much experience with Rust, might be a bit overkill for simple feature like this, but I guess so? @juliusmarminge

@mgrithm
Copy link

mgrithm commented Jul 18, 2023

Well, we could create this with typescript too.

@chungweileong94
Copy link
Contributor

Yeah, TS would be better, CI is a lot easy to setup.

@mgrithm
Copy link

mgrithm commented Jul 18, 2023

Can you setup the environment to me? I wanna work it :D (CI, pnpm...)

@juliusmarminge
Copy link
Member

Go for it!

@mgrithm
Copy link

mgrithm commented Jul 18, 2023

@juliusmarminge, how can I send the project to you?

@juliusmarminge
Copy link
Member

@juliusmarminge, how can I send the project to you?

You make a PR

@nullrodri
Copy link

@moliveiraz are you working on this? If not, I could take it :)

@juliusmarminge juliusmarminge added the PRs Accepted Feel free to pick this up and make a PR label Jul 30, 2023
@imMohika imMohika linked a pull request Sep 10, 2023 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PRs Accepted Feel free to pick this up and make a PR
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants