Merge branch 'meeb:main' into delete-source-reworked

This commit is contained in:
tcely 2025-03-28 00:50:31 -04:00 committed by GitHub
commit c7e1f88cb2
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
4 changed files with 17 additions and 2 deletions

View File

@ -20,7 +20,7 @@ outputs:
runs:
using: 'composite'
steps:
- name: Retrieve releases
- name: Set outputs
id: 'set'
env:
INPUT_STRING: '${{ inputs.string }}'

10
.github/sh/library/variables.inc.sh vendored Normal file
View File

@ -0,0 +1,10 @@
#!/usr/bin/env sh
# For setting single line variables in the environment or output
set_sl_var() { local f='%s=%s\n' ; printf -- "${f}" "$@" ; } ;
# Used together to set multiple line variables in the environment or output
mk_delim() { local f='%s_EOF_%d_' ; printf -- "${f}" "$1" "${RANDOM}" ; } ;
open_ml_var() { local f=''\%'s<<'\%'s\n' ; printf -- "${f}" "$2" "$1" ; } ;
close_ml_var() { local f='%s\n' ; printf -- "${f}" "$1" ; } ;

View File

@ -83,7 +83,7 @@ jobs:
cat >| .ffmpeg.releases.json <<'EOF'
${{ needs.info.outputs.ffmpeg-releases }}
EOF
mk_delim() { printf -- '"%s_EOF_%d_"' "$1" "${RANDOM}" ; } ;
mk_delim() { local f='%s_EOF_%d_' ; printf -- "${f}" "$1" "${RANDOM}" ; } ;
open_ml_var() { local f=''\%'s<<'\%'s\n' ; printf -- "${f}" "$2" "$1" ; } ;
close_ml_var() { local f='%s\n' ; printf -- "${f}" "$1" ; } ;
{
@ -104,6 +104,8 @@ jobs:
close_ml_var "${delim}" "${var}" ;
unset -v delim jq_arg var ;
} >> "${GITHUB_ENV}"
cat -v "${GITHUB_ENV}"
rm -v -f .ffmpeg.releases.json
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx

View File

@ -145,6 +145,9 @@ class CommaSepChoiceField(models.CharField):
# The data was lost; we can regenerate it.
args_dict = {key: self.__dict__[key] for key in CommaSepChoice._fields}
args_dict['selected_choices'] = list(value)
# setting a string manually should not result in characters
if isinstance(value, str) and len(value) > 0:
args_dict['selected_choices'] = value.split(self.separator)
data = CommaSepChoice(**args_dict)
value = data.selected_choices
s_value = super().get_prep_value(value)