Advertisement
artiri_art

e

Jun 12th, 2025
790
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.40 KB | Pets | 0 0
  1. #!/bin/bash
  2.  
  3. # Check if a JSON file was provided
  4. if [ -z "$1" ]; then
  5.   echo "Usage: $0 tokens.json"
  6.   exit 1
  7. fi
  8.  
  9. # Clear previous token file
  10. > data/token.txt
  11.  
  12. # Parse tokens from the JSON file and loop through them
  13. index=1
  14. tokens=$(jq -r '.tokens[]' "$1")
  15.  
  16. for token in $tokens; do
  17.   echo "$token" > data/token.txt
  18.   pm2 start bot.js --name "Dankeventsbot$index"
  19.   index=$((index + 1))
  20. done
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement