Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Latest commit

 

History

8 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 

Repository files navigation

dev-sync

A small CLI tool for developers to trigger and monitor plugin set builds in
dev mode on Plenty systems.
It handles authentication automatically and caches the access token until it is
about to expire.


Features

  • 🔑 Automatic login with credentials per PID
  • 💾 Local token caching (~/.plenty_auth.env)
    → avoids unnecessary login requests
  • ⚙️ Simple config file in homedir (~/.plenty_config.yml)
    → keeps credentials outside of repo
  • 🚀 Trigger plugin set builds in dev mode
  • ⏳ Poll build status and display errors clearly

Installation

Clone this repo and make the script executable:

git clone https://github.com/plentymarkets/dev-sync.git
cd plenty-dev-sync
chmod +x syncPluginSet

Configuration

Each developer must create a hidden config file in their homedir:

# ~/.plenty_config.yml
70503:
  username: your_username
  password: "your_password"

⚠️ This file is not part of the repo.
Each developer manages their own credentials locally.


Usage

Run the command with PID and Set ID:

./syncPluginSet <PID> <SET_ID>

Example:

./syncPluginSet 70503 1
  • 70503 → your Plenty account PID
  • 1 → plugin set ID you want to build in dev mode

Token caching

  • First run → logs in and saves token in ~/.plenty_auth.env
  • Subsequent runs → reuses the token
  • If the token is close to expiry (< 5 minutes left), a new login request is made automatically

Example output

🚀 Starting plugin build for set 1 on PID 70503
✅ Build request sent
⏳ Waiting for build to finish...
🏁 Build finished
OK (6 tests, 0 failures)

Troubleshooting

Missing credentials

❌ Missing credentials for PID 70503 in ~/.plenty_config.yml

→ Add your PID, username, and password to ~/.plenty_config.yml.

Token expired
→ Automatically handled.
If issues persist, delete ~/.plenty_auth.env and rerun.


License

Internal tool for Plenty developers. Not for production use.

About

No description, website, or topics provided.

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages