2 Commits

Author SHA1 Message Date
03f8f12753 Update readme and new revision
All checks were successful
Unit Testing / test (3.11) (push) Successful in 47s
Unit Testing / test (3.8) (push) Successful in 47s
Unit Testing / test (3.10) (push) Successful in 53s
Unit Testing / test (3.12) (push) Successful in 54s
Unit Testing / test (3.9) (push) Successful in 53s
2026-03-18 11:17:04 +01:00
b5a1ac0d2b Debug Windows Release Issues (#8)
All checks were successful
Unit Testing / test (3.10) (push) Successful in 50s
Unit Testing / test (3.12) (push) Successful in 51s
Unit Testing / test (3.9) (push) Successful in 50s
Unit Testing / test (3.11) (push) Successful in 55s
Unit Testing / test (3.8) (push) Successful in 53s
Co-authored-by: Basil Bruhn <basil.bruhn@psi.ch>
Reviewed-on: #8
Co-authored-by: Artur Glavic <artur.glavic@psi.ch>
Co-committed-by: Artur Glavic <artur.glavic@psi.ch>
2026-03-18 11:15:24 +01:00
3 changed files with 83 additions and 56 deletions

View File

@@ -112,55 +112,71 @@ jobs:
if: ${{ (github.event_name != 'workflow_dispatch') || (contains(fromJson('["all", "windows", "all_incl_release"]'), github.event.inputs.build-items)) }}
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: 3.12
- name: Ensure build environment
shell: powershell
run: |
$envName="eos_build"
$envFile="conda_windows.yml"
$hashFile="$env:TEMP\$envName.hash"
- uses: actions/checkout@v4
$newHash = (Get-FileHash $envFile).Hash
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: 3.12
if (!(Test-Path $hashFile)) {
$rebuild = $true
} else {
$oldHash = Get-Content $hashFile
$rebuild = $oldHash -ne $newHash
}
- name: Ensure build environment
shell: powershell
run: |
$envName = "eos_build"
$envFile = "conda_windows.yml"
$hashFile = "$env:TEMP\$envName.hash"
if ($rebuild) {
Write-Host "Environment changed → rebuilding"
if (micromamba env list | Select-String $envName) {
micromamba env remove -n $envName -y 2>$null
}
micromamba create -n $envName -f $envFile -y
$newHash | Out-File $hashFile
} else {
Write-Host "Environment unchanged → using cached env"
}
- name: Determine release tag
shell: powershell
run: |
$tag = micromamba run -n eos_build python -c "import eos; print('v'+eos.__version__)"
$tag = $tag.Trim()
"RELEASE_TAG=$tag" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
- name: Build with pyinstaller
shell: powershell
run: |
micromamba activate eos_build
pyinstaller windows_build.spec
cd dist\eos
Compress-Archive -Path .\* -Destination ..\..\eos.zip
- name: Update Release
if: ${{ (github.event_name != 'workflow_dispatch') || (contains(fromJson('["all_incl_release"]'), github.event.inputs.build-items)) }}
uses: actions/gitea-release-action@v1
with:
name: "Amor-Eos ${{ env.RELEASE_TAG }}"
tag_name: "${{ env.RELEASE_TAG }}"
files: |-
eos.zip
$newHash = (Get-FileHash $envFile).Hash
if (!(Test-Path $hashFile)) {
$rebuild = $true
} else {
$oldHash = Get-Content $hashFile
$rebuild = $oldHash -ne $newHash
}
if ($rebuild) {
Write-Host "Environment changed → rebuilding"
if (micromamba env list | Select-String $envName) {
micromamba env remove -n $envName -y 2>$null
}
micromamba create -n $envName -f $envFile -y
$newHash | Out-File $hashFile
} else {
Write-Host "Environment unchanged → using cached env"
}
- name: Determine release tag
shell: powershell
run: |
$tag = micromamba run -n eos_build python -c "import eos; print('v'+eos.__version__)"
$tag = $tag.Trim()
Write-Host "Release tag: $tag"
Add-Content -Path $env:GITHUB_ENV -Value "RELEASE_TAG=$tag"
- name: Build with pyinstaller
shell: powershell
run: |
Write-Host "Building version: $env:RELEASE_TAG"
micromamba run -n eos_build pyinstaller windows_build.spec
Copy-Item README.rst dist\eos\
- name: Package artifact
shell: powershell
run: |
Compress-Archive -Path dist\eos\* -DestinationPath "amor_eos-win64-$env:RELEASE_TAG.zip"
- name: Update Release
if: ${{ (github.event_name != 'workflow_dispatch') || (contains(fromJson('["all_incl_release"]'), github.event.inputs.build-items)) }}
uses: actions/gitea-release-action@v1
with:
name: "Amor-Eos ${{ env.RELEASE_TAG }}"
tag_name: "${{ env.RELEASE_TAG }}"
files: |-
amor_eos-win64*.zip

View File

@@ -1,5 +1,6 @@
*************************************************************
EOS - The AMOR focusing reflectometry data reduction software
-------------------------------------------------------------
*************************************************************
.. image:: https://img.shields.io/pypi/v/amor-eos.svg
:target: https://pypi.python.org/pypi/amor-eos/
@@ -18,10 +19,20 @@ visualisation of the content of a raw file (.hdf):
:TODO: real readme for final system needed.
Installation
------------
Create a virtual python environment (>3.8) and install the PyPI package:
============
Python Environment
------------------
Create a [virtual python environment](https://docs.python.org/3/library/venv.html) (>3.8) and install the PyPI package:
pip install amor-eos
On Windows you can also use the binary eos.exe that you find in the
[GitHub Releases]([https://github.com/jochenstahn/amor/releases/latest) section
Windows Binary
--------------
On Windows you can use the binary eos.exe that you find in the
[Gitea Releases](https://gitea.psi.ch/sinq-reflectometry/eos/releases/latest) section.
Either extract it to the folder where you analyze your data or choose a common location and make sure
that is in the system PATH to be able to run the program from command line.

View File

@@ -2,5 +2,5 @@
Package to handle data redction at AMOR instrument to be used by __main__.py script.
"""
__version__ = '3.2.7'
__date__ = '2026-03-13'
__version__ = '3.2.8'
__date__ = '2026-03-18'