Skip to content

Commit 9134b59

Browse files
committed
fix merge conflicts
2 parents 64daf9c + a741546 commit 9134b59

File tree

262 files changed

+31088
-40249
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

262 files changed

+31088
-40249
lines changed
Lines changed: 73 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
name: install self-installer on Windows
2+
3+
on:
4+
workflow_dispatch: # Allows running this workflow manually
5+
# Runs on pushes targeting the default branch
6+
# push:
7+
# branches-ignore:
8+
# - master
9+
# branches: ['main']
10+
# pull_request:
11+
# branches: ['main']
12+
13+
14+
jobs:
15+
test-GSAS-II:
16+
#strategy:
17+
# fail-fast: false
18+
runs-on: 'windows-latest'
19+
steps:
20+
- uses: suisei-cn/actions-download-file@818d6b7dc8fe73f2f924b6241f2b1134ca1377d9 # 1.6.0
21+
id: downloadfile
22+
name: Download the file
23+
with:
24+
url: "https://github.com/AdvancedPhotonSource/GSAS-II-buildtools/releases/download/v1.0.1/gsas2new-5804-Windows-x86_64.exe"
25+
#target: download/
26+
#- name: find it
27+
# shell: bash
28+
# run: |
29+
# ls -R
30+
31+
- name: GSAS-II install
32+
shell: pwsh
33+
run: Start-Process -FilePath .\gsas2new-5804-Windows-x86_64.exe -ArgumentList "/S /AddToPath=1 " -NoNewWindow -Wait
34+
35+
#- name: find install
36+
# if: always()
37+
# shell: bash
38+
# run: |
39+
# ls -R
40+
41+
#- name: GSAS-II find GSAS-II
42+
# if: always()
43+
# shell: bash
44+
# run: |
45+
# cd c:/ProgramData/gsas2new/GSAS-II
46+
# ls
47+
48+
- name: try all tests
49+
if: always()
50+
shell: cmd
51+
run: |
52+
call c:\ProgramData\gsas2new\Scripts\activate
53+
python -VV
54+
call conda install -y --quiet pytest
55+
call cd c:\ProgramData\gsas2new\GSAS-II
56+
dir
57+
python -m pytest c:/ProgramData/gsas2new/GSAS-II
58+
59+
# #python -v -c "import sys; print(sys.path)"
60+
# python -c "import pyspg"
61+
62+
# - name: try ldd
63+
# if: always()
64+
# shell: bash -el {0}
65+
# run: |
66+
# #conda create -n ntldd python=3.12 numpy=2.2 m2w64-ntldd-git
67+
# conda create -n ntldd python=3.11 numpy=1.26 m2w64-ntldd-git
68+
# conda activate ntldd
69+
# cd GSAS-II/GSASII-bin/win_64_p3.11_n1.26
70+
# #cd GSAS-II/GSASII-bin/win_64_p3.12_n2.2
71+
# ls
72+
# ntldd *.pyd
73+
# python -c "import pyspg"

.github/old-workflows/win_test.yml

Lines changed: 97 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,97 @@
1+
name: debug self-tests on Windows w/3.11
2+
3+
on:
4+
workflow_dispatch: # Allows running this workflow manually
5+
# Runs on pushes targeting the default branch
6+
# push:
7+
# branches-ignore:
8+
# - master
9+
# branches: ['main']
10+
# pull_request:
11+
# branches: ['main']
12+
13+
14+
jobs:
15+
test-GSAS-II:
16+
strategy:
17+
fail-fast: false
18+
matrix:
19+
# python-version: ["3.11", "3.12", "3.13"]
20+
python-version: ["3.11"]
21+
# python-version: ["3.12"]
22+
runs-on: 'windows-latest'
23+
steps:
24+
- uses: conda-incubator/setup-miniconda@v3
25+
with:
26+
auto-update-conda: true
27+
python-version: ${{ matrix.python-version }}
28+
- name: Conda install
29+
shell: bash -el {0}
30+
run: |
31+
# tailor the numpy version to match the GSAS-II binaries
32+
if [ "${{ matrix.python-version }}" == "3.13" ]; then
33+
npver="2.2 python-gil"
34+
elif [ "${{ matrix.python-version }}" == "3.12" ]; then
35+
npver=2.2
36+
elif [ "${{ matrix.python-version }}" == "3.11" ]; then
37+
npver=1.26
38+
fi
39+
#conda list
40+
#conda info
41+
conda install python=${{ matrix.python-version }} numpy=${npver} scipy requests pytest git gitpython pycifrw -c conda-forge --override-channels --quiet
42+
#conda install --quiet numpy=${npver} requests pytest briantoby::gsas2pkg -c conda-forge
43+
conda info
44+
conda list
45+
- name: GSAS-II install
46+
shell: bash -el {0}
47+
run: |
48+
#mkdir G2
49+
#cd G2
50+
curl -L -O https://github.com/AdvancedPhotonSource/GSAS-II-buildtools/raw/main/install/gitstrap.py
51+
python gitstrap.py --nocheck --noshortcut --branch=main
52+
53+
- name: find files
54+
shell: bash -el {0}
55+
run: |
56+
ls -l GSAS-II/GSASII-bin/win_64_p3.11_n1.26
57+
#ls -l GSAS-II/GSASII-bin/win_64_p3.12_n2.2
58+
ls -l GSAS-II/tests
59+
60+
- name: GSAS-II single test
61+
if: always()
62+
shell: bash -el {0}
63+
run: |
64+
cd GSAS-II
65+
python tests/test_elm.py
66+
python tests/test_spg.py
67+
68+
# - name: GSAS-II all tests
69+
# if: always()
70+
# shell: bash -el {0}
71+
# run: |
72+
# cd GSAS-II
73+
# ls
74+
# python -m pytest
75+
76+
- name: try pyspg
77+
if: always()
78+
shell: bash -el {0}
79+
run: |
80+
cd GSAS-II/GSASII-bin/win_64_p3.11_n1.26
81+
#cd GSAS-II/GSASII-bin/win_64_p3.12_n2.2
82+
python -VV
83+
python -c "import sys; print(sys.path)"
84+
python -c "import pyspg"
85+
86+
- name: try ldd
87+
if: always()
88+
shell: bash -el {0}
89+
run: |
90+
#conda create -n ntldd python=3.12 numpy=2.2 m2w64-ntldd-git
91+
conda create -n ntldd python=3.11 numpy=1.26 m2w64-ntldd-git
92+
conda activate ntldd
93+
cd GSAS-II/GSASII-bin/win_64_p3.11_n1.26
94+
#cd GSAS-II/GSASII-bin/win_64_p3.12_n2.2
95+
ls
96+
ntldd *.pyd
97+
python -c "import sys; sys.path.insert(0,'.'); import pyspg"

.github/workflows/TriggerRemote.yml

Lines changed: 18 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,24 @@
11
# when run, this starts GitHub Actions workflow in another repo (GSAS-II-buildtools)
22

3-
# 1) note that the GitHub Actions to be run must be on: repository_dispatch:
4-
# 2) in the organizaion owning the remote repo, one must create a Personal Access Token
5-
# (Org level) (Settings/Developer Settings/Personal Access Settings->Tokens
6-
# got this to work w/classic having this access allowed:
7-
# repo:status, repo_deployment, public_repo, repo:invite, security_events, manage_runners:org
8-
# better w/new style token, I guess
9-
# 3) save the created token in @ project-level: Settings/Secrets and vars/Actions: Repo secret
3+
# 1) This will trigger all GitHub Actions in workflows that has
4+
# on: repository_dispatch:
5+
# 2) an authorized user (Brian, or perhaps organization) creates a
6+
# personal access token.
7+
# Do this by clicking on "picture (upper rt)
8+
# then "Settings" in drop-down and
9+
# then select "Developer settings" (at bottom).
10+
# Finally select "Fine-grained tokens"
11+
# Personal access token settings:
12+
# select owner: APS;
13+
# select APS/G2-bld;
14+
# Repo permissions: contents r/w & metadata: r/o.
15+
# 3) Save the created token in this (G2) project.
16+
# Use repo-level settings on 2nd line from top (may be in ... menu).
17+
# Select Actions in Secrets & variables and create a repository secret.
18+
# Name assigned must match ${{ secrets.XXX }} in workflow's curl
19+
# call ("Authorization:" setting)
1020

11-
name: Trigger on GSASII-buildtools
21+
name: Test of triggering GSASII-buildtools actions
1222

1323
on: workflow_dispatch
1424

.github/workflows/smoke_test.yml

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
name: smoke test
2+
3+
on:
4+
# Runs on pushes targeting the default branch
5+
push:
6+
branches-ignore:
7+
- master
8+
# branches: ['develop']
9+
pull_request:
10+
branches: ['main']
11+
12+
# Allows you to run this workflow manually from the Actions tab
13+
workflow_dispatch:
14+
15+
16+
# Default to bash
17+
defaults:
18+
run:
19+
shell: bash
20+
21+
22+
jobs:
23+
build:
24+
strategy:
25+
fail-fast: false
26+
matrix:
27+
os:
28+
- name: 'ubuntu-22.04'
29+
- name: 'macos-latest'
30+
- name: 'windows-latest'
31+
# cmd_extra: '-win'
32+
env: ['py310', 'py311', 'py312', 'py313']
33+
runs-on: ${{ matrix.os.name }}
34+
steps:
35+
# checkout repo
36+
- uses: actions/checkout@v2
37+
38+
# set up pixi
39+
- uses: prefix-dev/[email protected]
40+
with:
41+
environments: ${{ matrix.env }}
42+
pixi-version: v0.39.5
43+
manifest-path: pixi/pixi.toml
44+
45+
# run install to see if it works
46+
- name: Build
47+
# run: pixi run --manifest-path pixi/pixi.toml -e ${{ matrix.env }} install${{ matrix.os.cmd_extra }}
48+
run: pixi run --manifest-path pixi/pixi.toml -e ${{ matrix.env }} install
49+
50+
- name: test
51+
run: pixi run --manifest-path pixi/pixi.toml -e ${{ matrix.env }} test
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
name: GSAS-II self-tests on Windows via gitstrap
2+
3+
on:
4+
workflow_dispatch: # Allows running this workflow manually
5+
# Runs on pushes targeting the default branch
6+
# push:
7+
# branches-ignore:
8+
# - master
9+
# branches: ['main']
10+
# pull_request:
11+
# branches: ['main']
12+
13+
14+
jobs:
15+
test-GSAS-II:
16+
strategy:
17+
fail-fast: false
18+
matrix:
19+
python-version: ["3.12", "3.13"]
20+
# python-version: ["3.11", "3.12", "3.13"]
21+
# python-version: ["3.13"]
22+
runs-on: 'windows-latest'
23+
steps:
24+
- uses: conda-incubator/setup-miniconda@v3
25+
with:
26+
auto-update-conda: true
27+
python-version: ${{ matrix.python-version }}
28+
- name: Conda install
29+
shell: bash -el {0}
30+
run: |
31+
# tailor the numpy version to match the GSAS-II binaries
32+
if [ "${{ matrix.python-version }}" == "3.13" ]; then
33+
npver="2.2 python-gil"
34+
elif [ "${{ matrix.python-version }}" == "3.12" ]; then
35+
npver=2.2
36+
elif [ "${{ matrix.python-version }}" == "3.11" ]; then
37+
npver=1.26
38+
fi
39+
conda install python=${{ matrix.python-version }} numpy=${npver} scipy requests pytest git gitpython pycifrw -c conda-forge --override-channels --quiet
40+
#conda info
41+
#conda list
42+
- name: GSAS-II install
43+
shell: bash -el {0}
44+
run: |
45+
curl -L -O https://github.com/AdvancedPhotonSource/GSAS-II-buildtools/raw/main/install/gitstrap.py
46+
python gitstrap.py --nocheck --noshortcut --branch=main
47+
48+
- name: GSAS-II all tests
49+
shell: bash -el {0}
50+
run: |
51+
cd GSAS-II
52+
python -m pytest

.gitignore

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,13 @@
1-
# GSAS-II settings, perhaps to be moved
1+
# obsolete GSAS-II settings file
22
config.py
33

44
# local code for debugging
55
debug_setup.py.example
66
debug_setup.py
77

8+
# created by install/saved-versions.py
9+
GSASII/saved_version.py
10+
811
# created on MacOS by makeMacApp.py
912
GSAS-II.app/
1013
GSAS-II.py
@@ -25,9 +28,20 @@ __pycache__
2528

2629
# from Spyder
2730
.spyproject
31+
2832
# GSAS binaries
2933
GSASII/bindist
34+
GSASII/bin
3035

3136
# Local dev env files
3237
.vscode
33-
.linenoteplus
38+
39+
40+
dist
41+
build
42+
43+
#
44+
*.gpx
45+
*.lst
46+
47+
*~

0 commit comments

Comments
 (0)