Zsh

1 program Added 2025-10-23T08:21:05Z Model: google/gemini-2.5-proTemp: 0.4 Evidence Report issue View issues
Aliases: Z shell
Provenance: commit da25fb4608 · authored 2025-10-23T10:21:05+02:00 · model google/gemini-2.5-pro

Sources mentioning this language

5 sources · pl_id: pl/bash
LLM (this repo) · 1PldbPygmentsWikipediaWikidata · Q204222

Wikipedia infobox

Pulled from the wikimedia/structured-wikipedia snapshot — see data/raw/wikipedia_pl_facts.*.jsonl and pl_fact.csv for the long-table provenance.

Designed byMartijn Dekker · Johnothan King · hyenias · Kurtis Rader · Siteshwar Vashisht · community
First appeared1983
LicenseEclipse Public License
Homepagehttp://github.com/ksh93/ksh/wiki

Extensions claimed by this language

12 claims. Each row is one upstream assertion with its strength. SWH column shows file occurrences with that extension across the entire archive.
ExtensionSourceStrengthSWH
.shpygmentsprimary50.4M files
.bashpygmentssecondary1.2M files
.bashrcpygmentssecondary32.8K files
.ebuildpygmentssecondary7.6M files
.eclasspygmentssecondary79.3K files
.exheres-0pygmentssecondary
.exlibpygmentssecondary48.0K files
.kshpygmentssecondary96.5K files
.kshrcpygmentssecondary296 files
.pkgbuildpygmentssecondary4.7K files
.zshpygmentssecondary785.3K files
.zshrcpygmentssecondary20.6K files

Related languages

csh (0.35)C Shell (0.30)Dash (0.26)Bourne Shell (0.25)Ion Shell (0.25)

LLM-contributed programs

Zsh weather script using wttr.in

Provenance: commit da25fb4608 · authored 2025-10-23T10:21:05+02:00 · model google/gemini-2.5-pro · Temp 0.4
code.zsh · added: 2025-10-23T08:21:05Z
#!/bin/zsh
#
# A simple script to get the weather from wttr.in
#
# Usage: weather [location] [options]
#
# Options:
#   -f: force update (don't use cached data)
#   -h: show help
#
# Example:
#   weather Munich
#   weather "New York"
#   weather London -f

zmodload zsh/datetime

CACHE_DIR=${XDG_CACHE_HOME:-$HOME/.cache}/weather
CACHE_FILE=$CACHE_DIR/$(echo "$*" | tr ' /' '_-').txt
CACHE_TIME=3600 # 1 hour

# Create cache dir if it doesn't exist
[ -d $CACHE_DIR ] || mkdir -p $CACHE_DIR

# Check for force update or expired cache
if ! [[ "$*" =~ "-f" ]] && [ -f $CACHE_FILE ] && (( $EPOCHSECONDS - $(stat -f %m $CACHE_FILE) < $CACHE_TIME )); then
    cat $CACHE_FILE
    exit 0
fi

# Remove -f from arguments
args=(${(s: :)@})
args=(${args:#-f})

# Show help
if [[ "$*" =~ "-h" ]]; then
    echo "Usage: weather [location] [options]"
    echo "Options:"
    echo "  -f: force update (don't use cached data)"
    echo "  -h: show help"
    exit 0
fi

# Get weather and save to cache
curl -s "wttr.in/$args" | tee $CACHE_FILE

Real programs from Software Heritage

1 sample mined from derived_datasets/<date>/contents/*.parquet, byte-verified against the SWH archive. Citation-grade qualified SWHIDs preserved.
set_ia32_sysroot.sh · 987 B · ext .sh · seen 13179× in SWH
via fallback
swh:1:cnt:194433040640d167e6aa4de66cedc6c8ebe03f2e;origin=https://github.com/dart-lang/sdk;anchor=swh:1:rev:523353d28017fced825581ea327509c620eed67e;path=/tools/set_ia32_sysroot.sh
Open in SWH · Raw bytes (SWH) · GitHub raw
Show source
#!/usr/bin/env bash
#
# Copyright (c) 2016, the Dart project authors.  Please see the AUTHORS file
# for details. All rights reserved. Use of this source code is governed by a
# BSD-style license that can be found in the LICENSE file.

# Sets the compiler environment variables to use a downloaded Debian sysroot
# when building Dart with architecture ia32.
# Run this in the same working directory that you have run
# sdk/tools/download_chromium_sysroot.sh in.
# Must be sourced, not run in a subshell, to modify the environment.
# Run with the command ". sdk/tools/set_ia32_sysroot.sh"
# Only tested and used on Ubuntu trusty linux. Used to build dart with
# no requirement for glibc greater than version 2.14.

export CXXFLAGS="--sysroot=$PWD/build/linux/debian_jessie_i386-sysroot -I=/usr/include/c++/4.8 -I=/usr/include/c++/4.8/i486-linux-gnu"

export LDFLAGS=--sysroot=$PWD/build/linux/debian_jessie_i386-sysroot
export CFLAGS=--sysroot=$PWD/build/linux/debian_jessie_i386-sysroot

Contribute — propose a file extension

Tell us where to find evidence about Zsh (mapped to pl/bash). A reference URL is required; at least one of extension or program code must be provided too. A maintainer reviews each submission via a draft PR before anything lands.
Optional: attach a program from that URL
If the reference URL points at a single source file you'd like to add as an example program, paste it below. The workflow will write it under languages/Zsh/programs/<sha>/. Keep under ~200 lines.
(or open the pre-filled issue directly)
← ZScript ZSPL →