Search found 1 match

by snick512
Sat Jun 07, 2025 8:08 pm
Forum: General
Topic: Post from command line
Replies: 0
Views: 15235

Post from command line

Hi!

Uses bash , curl, jq


#!/bin/bash

# Load configuration
CONFIG_FILE=".page_config"
if [[ ! -f "$CONFIG_FILE" ]]; then
echo "❌ Missing .page_config file. Please create it with API_URL, TOKEN, and AUTH."
exit 1
fi
source "$CONFIG_FILE"

# Prompt user for input
read -p "📝 Title: " TITLE
read ...