Skip to content

Commit 7dff0b9

Browse files
committed
Update metadata, badge, and citation for 2025-07-05
1 parent cf5bf12 commit 7dff0b9

3 files changed

Lines changed: 121 additions & 5 deletions

File tree

.zenodo.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@
55
"language": "eng",
66
"upload_type": "software",
77
"access_right": "open",
8-
"version": "2025-04-28-150-g2cd5bcf",
9-
"publication_date": "2025-07-04",
8+
"version": "2025-04-28-151-gcf5bf12",
9+
"publication_date": "2025-07-05",
1010
"creators": [
1111
{
1212
"name": "Porter, Matthew A.",
@@ -18,7 +18,7 @@
1818
"keywords": ["AI","Education","Healthcare","Post-Quantum Cryptography","Quantum","config","lua","neovim"],
1919
"related_identifiers": [
2020
{ "identifier": "https://github.com/qompassai/Lua", "relation": "isSupplementTo", "resource_type": "software" },
21-
{ "identifier": "https://github.com/qompassai/Lua/releases/tag/v2025-07-04", "relation": "isIdenticalTo", "resource_type": "software" },
21+
{ "identifier": "https://github.com/qompassai/Lua/releases/tag/v2025-07-05", "relation": "isIdenticalTo", "resource_type": "software" },
2222
{ "identifier": "https://orcid.org/0000-0002-0302-4812", "relation": "isAuthorOf", "resource_type": "person" },
2323
{ "identifier": "https://github.com/qompassai/Lua/actions", "relation": "isCompiledBy", "resource_type": "workflow" },
2424
{ "identifier": "https://loop.frontiersin.org/people/2230223", "relation": "isAuthorOf", "resource_type": "person" },

CITATION.cff

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ authors:
66
given-names: "Matthew A."
77
orcid: "https://orcid.org/0000-0002-0302-4812"
88
affiliation: "Qompass AI"
9-
version: "v2025-07-04"
10-
date-released: "2025-07-04"
9+
version: "v2025-07-05"
10+
date-released: "2025-07-05"
1111
repository-code: "https://github.com/qompassai/Lua"
1212
license: "Q-CDA-1.0"
1313
keywords:

scripts/quickstart.sh

Lines changed: 116 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,116 @@
1+
#!/usr/bin/env bash
2+
# qompassai/Lua/scripts/quickstart.sh
3+
# Qompass AI Diver Lua Quick Start
4+
# Copyright (C) 2025 Qompass AI, All rights reserved
5+
#####################################################
6+
set -euo pipefail
7+
declare -A MENU=(
8+
[1]="lua 5.1.5"
9+
[2]="lua 5.2.4"
10+
[3]="lua 5.3.6"
11+
[4]="lua 5.4.6"
12+
[5]="luajit"
13+
)
14+
echo "╭─────────────────────────────────────────────╮"
15+
echo "│ Qompass AI · Lua Quick-Start │"
16+
echo "╰─────────────────────────────────────────────╯"
17+
echo " © 2025 Qompass AI. All rights reserved "
18+
echo
19+
for k in "${!MENU[@]}"; do printf " %s) %s\n" "$k" "${MENU[$k]}"; done
20+
echo " a) all (default)"
21+
echo " q) quit"
22+
echo
23+
read -rp "Choose versions to build [a]: " choice
24+
choice=${choice:-a}
25+
[[ $choice == q ]] && exit 0
26+
VERSIONS=()
27+
if [[ $choice == a ]]; then
28+
VERSIONS=(5.1.5 5.2.4 5.3.6 5.4.6 luajit)
29+
else
30+
for n in $choice; do
31+
case $n in
32+
1) VERSIONS+=("5.1.5") ;;
33+
2) VERSIONS+=("5.2.4") ;;
34+
3) VERSIONS+=("5.3.6") ;;
35+
4) VERSIONS+=("5.4.6") ;;
36+
5) VERSIONS+=("luajit") ;;
37+
*)
38+
echo "Unknown option $n"
39+
exit 1
40+
;;
41+
esac
42+
done
43+
fi
44+
PREFIX="$HOME/.local"
45+
JOBS=$(nproc 2>/dev/null || sysctl -n hw.ncpu || echo 4)
46+
: "${CC:=clang}"
47+
CFLAGS="-O3 -march=native -flto -fPIC -pipe"
48+
LDFLAGS="-flto -Wl,-O1,--as-needed"
49+
[[ -x $(command -v ld.lld) ]] && LDFLAGS+=" -fuse-ld=lld"
50+
case "$(uname -s)" in
51+
Darwin*)
52+
PLATFORM=macosx
53+
SHARED="-DLUA_USE_MACOSX"
54+
;;
55+
MINGW* | MSYS* | CYG*)
56+
PLATFORM=mingw
57+
SHARED=""
58+
;;
59+
*)
60+
PLATFORM=linux
61+
SHARED="-DLUA_USE_LINUX"
62+
;;
63+
esac
64+
add_to_rc() {
65+
local rc_file=$1
66+
local line="export PATH='$HOME/.local/bin:$PATH'"
67+
if [[ -f "$rc_file" ]] && ! grep -Fq "$line" "$rc_file"; then
68+
printf '\n# added by lua quickstart\n%s\n' "$line" >>"$rc_file"
69+
echo " -> PATH updated in $rc_file"
70+
fi
71+
}
72+
mkdir -p "$PREFIX/bin"
73+
cd /tmp
74+
for v in "${VERSIONS[@]}"; do
75+
if [[ $v == luajit ]]; then
76+
echo -e "\n=== LuaJIT ==="
77+
git clone --depth 1 https://github.com/LuaJIT/LuaJIT.git
78+
cd LuaJIT
79+
make -j"$JOBS" CC="$CC" CFLAGS="$CFLAGS" LDFLAGS="$LDFLAGS"
80+
make install PREFIX="$PREFIX/luajit"
81+
ln -sf "$PREFIX/luajit/bin/luajit" "$PREFIX/bin/luajit"
82+
cd /tmp && rm -rf LuaJIT
83+
continue
84+
fi
85+
echo -e "\n=== Lua $v ==="
86+
curl -fsSLO "https://www.lua.org/ftp/lua-$v.tar.gz"
87+
tar xf "lua-$v.tar.gz"
88+
rm "lua-$v.tar.gz"
89+
cd "lua-$v"
90+
make "$PLATFORM" \
91+
CC="$CC" \
92+
MYCFLAGS="$CFLAGS $SHARED" \
93+
MYLDFLAGS="$LDFLAGS" \
94+
-j"$JOBS"
95+
$CC "$CFLAGS" -shared -o src/liblua.so \
96+
-Wl,--whole-archive src/liblua.a -Wl,--no-whole-archive -lm
97+
short=${v%.*}
98+
dest="$PREFIX/lua$short"
99+
make install INSTALL_TOP="$dest"
100+
install -m 755 src/liblua.so "$dest/lib"
101+
ln -sf "$dest/bin/lua" "$PREFIX/bin/lua$short"
102+
ln -sf "$dest/bin/luac" "$PREFIX/bin/luac$short"
103+
cd /tmp && rm -rf "lua-$v"
104+
done
105+
add_to_rc "$HOME/.bashrc"
106+
add_to_rc "$HOME/.zshrc"
107+
if [[ -n ${PROFILE:-} && -f "$PROFILE" ]]; then
108+
if ! grep -Fq '.local/bin' "$PROFILE"; then
109+
printf "\n# added by lua quickstart\n$Env:Path = "%s
110+
" + $Env:Path\n" \
111+
"$HOME/.local/bin" >>"$PROFILE"
112+
echo " -> PATH updated in PowerShell profile: $PROFILE"
113+
fi
114+
fi
115+
116+
echo -e "\n✔ Build complete. Open a new shell or run: source ~/.bashrc"

0 commit comments

Comments
 (0)