Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[pull] release from mulle-nat:release #1

Open
wants to merge 4 commits into
base: release
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
51 changes: 51 additions & 0 deletions .github/workflows/mulle-sde-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: CI

on: [push]

env:
BUILD_TYPE: release
OTHER_PROJECTS: "MulleFoundation/foundation-developer;
MulleFoundation/mulle-foundation-developer;
mulle-objc/mulle-objc-developer;
mulle-c/mulle-c-developer;"

jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ ubuntu-latest] # macos-latest,

steps:
- name: Set MULLE_HOSTNAME
run: |
name="${GITHUB_REF##*/}"
MULLE_HOSTNAME="${MULLE_HOSTNAME:-ci-${name##*-}}"
echo "MULLE_HOSTNAME=${MULLE_HOSTNAME}" >> $GITHUB_ENV

- name: Add to path
run: echo "$HOME/bin" >> $GITHUB_PATH

- name: Dump Environment
run: env | sort

- uses: actions/checkout@v3

- uses: mulle-sde/github-ci@v1

- uses: mulle-cc/github-ci@v4

- name: Dump Project Environment
run: |
[ ! -d .mulle/etc/env ] || ls -l .mulle/etc/env/environment*.sh
mulle-sde environment

- name: Mulle-SDE Fetch
run: mulle-sde fetch

- name: Mulle-SDE Craft
run: mulle-sde craft --${BUILD_TYPE:-release}

- name: Mulle-SDE Test
run: |
[ ! -d test ] || mulle-sde test
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -51,3 +51,4 @@ src/PBXSupport/
mulle-project/
generate-brew-formula.sh
.mullex/
*.old
25 changes: 25 additions & 0 deletions .mulle/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# .mulle

This `.mulle` folder is used by [mulle-sde](//mulle-sde.github.io) to
store project information.

## Structure

* `etc` is user editable, changes will be preserved.
* `share` is read only, changes will be lost on the next upgrade.
* `var` is ephemeral. You can delete and it will get recreated.

Every mulle-sde tool may have its own subfolder within those three folders.
It's name will be the name of the tool without the "mulle-" prefix.

You can edit the files in `etc` with any editor, but for consistency and
ease of use, it's usually better to use the appropriate mulle-sde tool.

## Remove .mulle

The share folder is often write protected, to prevent accidental user edits.

```
chmod -R ugo+rwX .mulle && rm -rf .mulle
```

1 change: 1 addition & 0 deletions .mulle/etc/env/auxscope
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
project;20
1 change: 0 additions & 1 deletion .mulle/etc/project/version

This file was deleted.

11 changes: 3 additions & 8 deletions .mulle/etc/project/version-info.sh
Original file line number Diff line number Diff line change
@@ -1,8 +1,3 @@
# -- Version Info --
#
# Keep these commented out, if the automatic detection works well
# enough for you. If you don't have this file, there will be
# not git operations.
#
VERSIONFILE=mulle-xcode-to-cmake.xcodeproj/project.pbxproj
VERSIONNAME=CURRENT_PROJECT_VERSION
VERSIONNAME="CURRENT_PROJECT_VERSION"
VERSIONFILE="CMakeLists.txt"
VERSIONXCODEPROJ="mulle-xcode-to-cmake.xcodeproj/project.pbxproj"
4 changes: 2 additions & 2 deletions .mulle/share/env/auxscope
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
project
extension
extension;30
post-extension;210
4 changes: 4 additions & 0 deletions .mulle/share/env/environment-plugin-os-darwin.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,8 @@
# Git mirror and Zip/TGZ cache to conserve bandwidth
#
export MULLE_FETCH_MIRROR_DIR="${HOME:-/tmp}/Library/Caches/mulle-fetch/git-mirror"

#
# Git mirror and Zip/TGZ cache to conserve bandwidth
#
export MULLE_FETCH_ARCHIVE_DIR="${HOME:-/tmp}/Library/Caches/mulle-fetch/archive"
29 changes: 5 additions & 24 deletions .mulle/share/env/environment-plugin.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#
# Git mirror and Zip/TGZ cache to conserve bandwidth
# Memo: override in os-specific env file
# Memo: Will often be overridden in an os-specific environment file
# Can be overridden with -DMULLE_FETCH_ARCHIVE_DIR on the commandline
#
export MULLE_FETCH_MIRROR_DIR="${HOME:-/tmp}/.cache/mulle-fetch/git-mirror"

Expand All @@ -10,37 +11,17 @@ export MULLE_FETCH_MIRROR_DIR="${HOME:-/tmp}/.cache/mulle-fetch/git-mirror"
export MULLE_FETCH_ARCHIVE_DIR="${HOME:-/tmp}/.cache/mulle-fetch/archive"

#
# PATH to search for git repositories locally
# PATH to search for git repositories locally.
#
export MULLE_FETCH_SEARCH_PATH="${MULLE_VIRTUAL_ROOT}/.."

#
# Prefer symlinking to local git repositories found via MULLE_FETCH_SEARCH_PATH
# Prefer symlinks to clones of git repos found in MULLE_FETCH_SEARCH_PATH
#
export MULLE_SOURCETREE_SYMLINK="YES"

#
# Use common folder for sharable projects
#
export MULLE_SOURCETREE_STASH_DIRNAME="stash"

#
# Share dependency directory (absolute for ease of use)
#
export DEPENDENCY_DIR="${MULLE_VIRTUAL_ROOT}/dependency"

#
# Share addiction directory (absolute for ease of use)
#
export ADDICTION_DIR="${MULLE_VIRTUAL_ROOT}/addiction"

#
# Use common build directory
#
export KITCHEN_DIR="${MULLE_VIRTUAL_ROOT}/kitchen"
#
#
#
export MULLE_SDE_INSTALLED_VERSION="0.39.4"
export MULLE_SDE_INSTALLED_VERSION="2.1.0"


48 changes: 19 additions & 29 deletions .mulle/share/env/environment.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,26 +7,6 @@
# If mulle-env is broken, sometimes its nice just to source this file.
# If you're sourcing this manually on a regular basis, you're doing it wrong.
#
# We need some minimal stuff to get things going though:
# sed, cut, tr, hostname, pwd, uname
#
if [ -z "${MULLE_UNAME}" ]
then
MULLE_UNAME="`PATH=/bin:/usr/bin uname | \
PATH=/bin:/usr/bin cut -d_ -f1 | \
PATH=/bin:/usr/bin sed 's/64$//' | \
PATH=/bin:/usr/bin tr 'A-Z' 'a-z'`"
export MULLE_UNAME
fi
if [ -z "${MULLE_HOSTNAME}" ]
then
MULLE_HOSTNAME="`PATH=/bin:/usr/bin:/sbin:/usr/sbin hostname -s`"
if [ "${MULLE_HOSTNAME:0:1}" = '.' ]
then
MULLE_HOSTNAME="_${MULLE_HOSTNAME}"
fi
export MULLE_HOSTNAME
fi
if [ -z "${MULLE_VIRTUAL_ROOT}" ]
then
MULLE_VIRTUAL_ROOT="`PATH=/bin:/usr/bin pwd -P`"
Expand Down Expand Up @@ -73,21 +53,31 @@ case "${MULLE_SHELL_MODE}" in

alias mulle-env-reload='. "${MULLE_VIRTUAL_ROOT}/.mulle/share/env/include-environment.sh"'


#
# source in any bash completion files
#
DEFAULT_IFS="${IFS}"
shopt -s nullglob; IFS=$'\n'
IFS=$'\n'
# memo: nullglob not easily done on both bash and zsh
for FILENAME in "${MULLE_VIRTUAL_ROOT}/.mulle/share/env/libexec"/*-bash-completion.sh
do
. "${FILENAME}"
if [ -f "${FILENAME}" ]
then
. "${FILENAME}"
fi
done
shopt -u nullglob; IFS="${DEFAULT_IFS}"
IFS="${DEFAULT_IFS}"

unset FILENAME
unset DEFAULT_IFS
unset FILENAME

vardir="${MULLE_VIRTUAL_ROOT}/.mulle/var/${MULLE_HOSTNAME}"
[ -d "${vardir}" ] || mkdir -p "${vardir}"

HISTFILE="${vardir}/bash_history"
export HISTFILE

unset vardir

#
# show motd, if any
Expand Down Expand Up @@ -132,9 +122,9 @@ case "${MULLE_SHELL_MODE}" in
alias log="mulle-sde log"
alias match="mulle-sde match"
alias monitor="mulle-sde monitor"
alias reflect="mulle-sde reflect"
alias patternfile="mulle-sde patternfile"
alias subproject="mulle-sde subproject"
alias update="mulle-sde update"
fi

if [ -z "" ]
Expand All @@ -145,9 +135,9 @@ case "${MULLE_SHELL_MODE}" in
alias t="mulle-sde test rerun --serial"
alias tt="mulle-sde test craft ; mulle-sde test rerun --serial"
alias T="mulle-sde test craft ; mulle-sde test"
alias TT="mulle-sde test clean ; mulle-sde test"
alias u="mulle-sde update"
alias l="mulle-sde list"
alias TT="mulle-sde test clean all; mulle-sde test"
alias r="mulle-sde reflect"
alias l="mulle-sde list --files"
fi
;;
esac
111 changes: 52 additions & 59 deletions .mulle/share/env/include-environment.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,89 +4,82 @@ and MULLE_UNAME properly" >&2 && exit 1

MULLE_ENV_SHARE_DIR="${MULLE_VIRTUAL_ROOT}/.mulle/share/env"
MULLE_ENV_ETC_DIR="${MULLE_VIRTUAL_ROOT}/.mulle/etc/env"
# Top/down order of inclusion. Left overrides right if present.
# Top/down order of inclusion.
# Keep these files (except environment-custom.sh) clean off manual edits so
# that mulle-env can read and set environment variables.
#
# .mulle/etc/env | .mulle/share/env
# --------------------------------------|--------------------
# | environment-plugin.sh
# | environment-plugin-os-${MULLE_UNAME}.sh
# | environment-project.sh
# | environment-extension.sh
# environment-project.sh |
# environment-global.sh |
# environment-os-${MULLE_UNAME}.sh |
# environment-host-${MULLE_HOSTNAME}.sh |
# environment-user-${USER}.sh |
# environment-user-${MULLE_USERNAME}.sh |
# environment-custom.sh |
#
# environment-post-global.sh |
#
scopes="s:plugin;5
s:plugin-os-${MULLE_UNAME};15
e:global;40
e:os-${MULLE_UNAME};60
e:host-${MULLE_HOSTNAME};80
e:user-${MULLE_USERNAME};100
e:custom;1000
e:post-global;2000"

#
# The plugin file, if present is to be set by a mulle-env plugin
#
if [ -f "${MULLE_ENV_SHARE_DIR}/environment-plugin.sh" ]
if [ -f "${MULLE_ENV_ETC_DIR}/auxscope" ]
then
. "${MULLE_ENV_SHARE_DIR}/environment-plugin.sh"
auxscopes="`PATH=/bin:/usr/bin sed -e 's/^/e:/' \
-e "s/\${MULLE_UNAME}/${MULLE_UNAME}/" \
-e "s/\${MULLE_HOSTNAME}/${MULLE_HOSTNAME}/" \
-e "s/\${MULLE_USERNAME}/${MULLE_USERNAME}/" \
"${MULLE_ENV_ETC_DIR}/auxscope"`"
scopes="${scopes}"$'\n'"${auxscopes}"
fi

#
# The plugin file, if present is to be set by a mulle-env plugin
#
if [ -f "${MULLE_ENV_SHARE_DIR}/environment-plugin-os${MULLE_UNAME}.sh" ]
if [ -f "${MULLE_ENV_SHARE_DIR}/auxscope" ]
then
. "${MULLE_ENV_SHARE_DIR}/environment-plugin-os${MULLE_UNAME}.sh"
auxscopes="`PATH=/bin:/usr/bin sed -e 's/^/s:/' \
-e "s/\${MULLE_UNAME}/${MULLE_UNAME}/" \
-e "s/\${MULLE_HOSTNAME}/${MULLE_HOSTNAME}/" \
-e "s/\${MULLE_USERNAME}/${MULLE_USERNAME}/" \
"${MULLE_ENV_SHARE_DIR}/auxscope"`"
scopes="${scopes}"$'\n'"${auxscopes}"
fi


#
# The project file, if present is to be set by mulle-sde init itself
# w/o extensions
# Load scopes according to priority now
#
if [ -f "${MULLE_ENV_SHARE_DIR}/environment-project.sh" ]
then
. "${MULLE_ENV_SHARE_DIR}/environment-project.sh"
fi
for scope in `printf "%s\n" "${scopes}" \
| PATH=/bin:/usr/bin sort -t';' -k2n -k1 \
| PATH=/bin:/usr/bin sed -n -e 's/\(.*\);.*$/\1/p'`
do
case "${scope}" in
e:*)
includefile="${MULLE_ENV_ETC_DIR}/environment-${scope#?:}.sh"
;;

#
# The extension file, if present is to be set by mulle-sde extensions.
#
if [ -f "${MULLE_ENV_SHARE_DIR}/environment-extension.sh" ]
then
. "${MULLE_ENV_SHARE_DIR}/environment-extension.sh"
fi
s:*)
includefile="${MULLE_ENV_SHARE_DIR}/environment-${scope#?:}.sh"
;;

#
# Global user settings
#
if [ -f "${MULLE_ENV_ETC_DIR}/environment-global.sh" ]
then
. "${MULLE_ENV_ETC_DIR}/environment-global.sh"
fi
*)
continue;
;;
esac

#
# Load in some user modifications depending on os, hostname, username.
#
if [ -f "${MULLE_ENV_ETC_DIR}/environment-host-${MULLE_HOSTNAME}.sh" ]
then
. "${MULLE_ENV_ETC_DIR}/environment-host-${MULLE_HOSTNAME}.sh"
fi

if [ -f "${MULLE_ENV_ETC_DIR}/environment-os-${MULLE_UNAME}.sh" ]
then
. "${MULLE_ENV_ETC_DIR}/environment-os-${MULLE_UNAME}.sh"
fi
if [ -f "${includefile}" ]
then
. "${includefile}"
fi
done

if [ -f "${MULLE_ENV_ETC_DIR}/environment-user-${USER}.sh" ]
then
. "${MULLE_ENV_ETC_DIR}/environment-user-${USER}.sh"
fi
unset scope
unset scopes
unset auxscopes
unset includefile

#
# For more complex edits, that don't work with the cmdline tool
#
if [ -f "${MULLE_ENV_ETC_DIR}/environment-custom.sh" ]
then
. "${MULLE_ENV_ETC_DIR}/environment-custom.sh"
fi
unset MULLE_ENV_ETC_DIR
unset MULLE_ENV_SHARE_DIR
Loading