Searching We.Love.Privacy.Club

Twts matching #export
Sort by: Newest, Oldest, Most Relevant

Apple farmers exit industry after pocketing a rise of just 50c a kilo in 20 years
Retail fruit prices have barely changed in two decades, exports have dropped to around two per cent of the nation’s crop and producers are fleeing the industry, new data from a NSW Farmers Association survey reveals. ⌘ Read more

⤋ Read More

Grape growers eye off diverse new markets for export
Wine exporters across regional Victoria are building stronger ties with overseas countries to offload a glut of red wine, in what is being described as one of the most challenging harvests the sector has ever seen. ⌘ Read more

⤋ Read More

How to create a keyboard shortcut to export the current slide in Keynote
Lately I’ve been using Apple Keynote to create graphics for using in videos and blog posts. It’s a quick way to arrange things on a page, copying and pasting most things just works, and there are enough built in shapes and tools to get the point across. However, after spending a full day creating graphics for a video, I found myself frustrated by the number of clicks required to export a single slide at a time. ⌘ Read more

⤋ Read More

How’s the China-India economic relationship changed 2 years on from the deadly Galwan Valley border clash?
China’s exports to India grew to US$27.1 billion in the first quarter of 2022, but India is concerned by its ballooning trade deficit with its neighbour amid strained ties two years after the deadly Galwan Valley clash. ⌘ Read more

⤋ Read More

China’s world’s factory tag threatened by Vietnam, but ‘there’s nothing to worry about’, analysts say
Vietnam’s first quarter exports reached US$88.58 billion, up by 12.9 per cent from the previous year, with Chinese state media comparing the shipments in the first three months of the year to China’s main export hub of Shenzhen. ⌘ Read more

⤋ Read More

@prologic@twtxt.net

#!/bin/sh

# Validate environment
if ! command -v msgbus > /dev/null; then
    printf "missing msgbus command. Use:  go install git.mills.io/prologic/msgbus/cmd/msgbus@latest"
    exit 1
fi

if ! command -v salty > /dev/null; then
    printf "missing salty command. Use:  go install go.mills.io/salty/cmd/salty@latest"
    exit 1
fi

if ! command -v salty-keygen > /dev/null; then
    printf "missing salty-keygen command. Use:  go install go.mills.io/salty/cmd/salty-keygen@latest"
    exit 1
fi

if [ -z "$SALTY_IDENTITY" ]; then
    export SALTY_IDENTITY="$HOME/.config/salty/$USER.key"
fi

get_user () {
    user=$(grep user: "$SALTY_IDENTITY" | awk '{print $3}')
    if [ -z "$user" ]; then
        user="$USER"
    fi
    echo "$user"
}

stream () {
    if [ -z "$SALTY_IDENTITY" ]; then
        echo "SALTY_IDENTITY not set"
        exit 2
    fi

    jq -r '.payload' | base64 -d | salty -i "$SALTY_IDENTITY" -d
}

lookup () {
    if [ $# -lt 1 ]; then
    printf "Usage: %s nick@domain\n" "$(basename "$0")"
    exit 1
    fi

    user="$1"
    nick="$(echo "$user" | awk -F@ '{ print $1 }')"
    domain="$(echo "$user" | awk -F@ '{ print $2 }')"

    curl -qsSL "https://$domain/.well-known/salty/${nick}.json"
}

readmsgs () {
    topic="$1"

    if [ -z "$topic" ]; then
        topic=$(get_user)
    fi

    export SALTY_IDENTITY="$HOME/.config/salty/$topic.key"
    if [ ! -f "$SALTY_IDENTITY" ]; then
        echo "identity file missing for user $topic" >&2
        exit 1
    fi

    msgbus sub "$topic" "$0"
}

sendmsg () {
    if [ $# -lt 2 ]; then
        printf "Usage: %s nick@domain.tld <message>\n" "$(basename "$0")"
        exit 0
    fi

    if [ -z "$SALTY_IDENTITY" ]; then
        echo "SALTY_IDENTITY not set"
        exit 2
    fi

    user="$1"
    message="$2"

    salty_json="$(mktemp /tmp/salty.XXXXXX)"

    lookup "$user" > "$salty_json"

    endpoint="$(jq -r '.endpoint' < "$salty_json")"
    topic="$(jq -r '.topic' < "$salty_json")"
    key="$(jq -r '.key' < "$salty_json")"

    rm "$salty_json"

    message="[$(date +%FT%TZ)] <$(get_user)> $message"

    echo "$message" \
        | salty -i "$SALTY_IDENTITY" -r "$key" \
        | msgbus -u "$endpoint" pub "$topic"
}

make_user () {
    mkdir -p "$HOME/.config/salty"

    if [ $# -lt 1 ]; then
        user=$USER
    else
        user=$1
    fi

    identity_file="$HOME/.config/salty/$user.key"

    if [ -f "$identity_file" ]; then
        printf "user key exists!"
        exit 1
    fi

    # Check for msgbus env.. probably can make it fallback to looking for a config file?
    if [ -z "$MSGBUS_URI" ]; then
        printf "missing MSGBUS_URI in environment"
        exit 1
    fi


    salty-keygen -o "$identity_file"
    echo "# user: $user" >> "$identity_file"

    pubkey=$(grep key: "$identity_file" | awk '{print $4}')

    cat <<- EOF
Create this file in your webserver well-known folder. https://hostname.tld/.well-known/salty/$user.json

{
  "endpoint": "$MSGBUS_URI",
  "topic": "$user",
  "key": "$pubkey"
}

EOF
}

# check if streaming
if [ ! -t 1 ]; then
    stream
    exit 0
fi

# Show Help
if [ $# -lt 1 ]; then
    printf "Commands: send read lookup"
    exit 0
fi


CMD=$1
shift

case $CMD in
    send)
        sendmsg "$@"
    ;;
    read)
        readmsgs "$@"
    ;;
    lookup)
        lookup "$@"
    ;;
    make-user)
        make_user "$@"
    ;;
esac

⤋ Read More

some good initial progress with the !weewiki zettelkasten. messages can be made and tied to previous messages by providing partial UUIDs (that then get automatically expanded). basic export also works. #updates

⤋ Read More

The master plan is to export the !worgle bits of !monolith to a !weewiki, then begin adding user-level documentation that is able to dynamically reference bits of source code as another wiki page.

⤋ Read More

Bad idea of the day: a prolog repl, except pred definitions are checked in reverse definition order and all pred definitions not starting with underscore are persistent. you can export the persistent environment image as a regular prolog file.

⤋ Read More