Skip to content

Commit 080dcde

Browse files
authored
fix: Debian (macOS) compatibility (and GH workflows) (#415)
1 parent 560e2e1 commit 080dcde

133 files changed

Lines changed: 47902 additions & 46892 deletions

File tree

Some content is hidden

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

.editorconfig

Lines changed: 9 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,24 @@
1-
# EditorConfig is awesome: http://EditorConfig.org
1+
# EditorConfig: https://EditorConfig.org
22

33
# top-most EditorConfig file
44
root = true
55

6-
# Unix-style newlines with a newline ending every file
6+
# Global settings for all files
77
[*]
8+
charset = utf-8
89
end_of_line = lf
910
insert_final_newline = true
1011
trim_trailing_whitespace = true
11-
charset = utf-8
1212

13-
# 4 space indentation
14-
[*.{py,java,r,R}]
1513
indent_style = space
16-
indent_size = 4
14+
indent_size = 2
15+
tab_width = 2
1716

18-
# 2 space indentation
19-
[*.{js,json,y{a,}ml,html,cwl}]
17+
#### File Type Overrides ####
18+
19+
[*.{py,java,r,R}]
2020
indent_style = space
21-
indent_size = 2
21+
indent_size = 4
2222

2323
[*.{md,Rmd,rst}]
2424
trim_trailing_whitespace = false
25-
indent_style = space
26-
indent_size = 2

.github/dependabot.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,6 @@ updates:
66
schedule:
77
interval: "monthly"
88
- package-ecosystem: "bundler"
9-
directory: "/"
9+
directory: "/docs"
1010
schedule:
1111
interval: "monthly"

.github/workflows/deploy-package.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,12 @@ jobs:
2727
- name: Setup Python
2828
uses: actions/setup-python@v5
2929
with:
30-
python-version: "3.x"
30+
python-version: 3.12
3131

3232
- name: Build library
33-
run: python3 -m pip install build --user
33+
run: |
34+
pip install -U --upgrade-strategy=only-if-needed pip
35+
python3 -m pip install build --user
3436
3537
- name: Build wheel and tarball
3638
run: python3 -m build

.github/workflows/deploy-website.yml

Lines changed: 13 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@ name: Deploy website
22

33
on: workflow_dispatch
44

5+
permissions:
6+
contents: read
7+
58
concurrency:
69
group: docs-website
710

@@ -12,10 +15,16 @@ jobs:
1215
deploy:
1316
name: Cloudflare Pages
1417
runs-on: ubuntu-latest
18+
defaults:
19+
run:
20+
working-directory: docs
21+
env:
22+
BUNDLE_GEMFILE: ${{github.workspace}}/docs/Gemfile
23+
JEKYLL_GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
1524

1625
environment:
1726
name: stockindicators.dev
18-
url: ${{ steps.deploy.outputs.deployment-alias-url }}
27+
url: ${{ steps.deploy.outputs.pages-deployment-alias-url }}
1928

2029
steps:
2130
- name: Checkout source
@@ -24,9 +33,11 @@ jobs:
2433
- name: Setup Ruby
2534
uses: ruby/setup-ruby@v1
2635
with:
27-
working-directory: docs
2836
ruby-version: 3.3
2937

38+
- name: Install dependencies
39+
run: bundle install
40+
3041
- name: Define tag
3142
id: tag
3243
run: echo "version=$(date +'%Y.%m.%d')-${{ github.run_number }}" >> $GITHUB_OUTPUT
@@ -38,28 +49,16 @@ jobs:
3849
replace: "${{ steps.tag.outputs.version }}"
3950
regex: false
4051

41-
- name: Install GEMs
42-
working-directory: docs
43-
env:
44-
BUNDLE_GEMFILE: ${{github.workspace}}/docs/GemFile
45-
run: |
46-
pwd
47-
bundle install
48-
4952
- name: Build site (production)
5053
if: github.ref == 'refs/heads/main'
51-
working-directory: docs
5254
env:
5355
JEKYLL_ENV: production
54-
BUNDLE_GEMFILE: ${{github.workspace}}/docs/GemFile
5556
run: bundle exec jekyll build
5657

5758
- name: Build site (preview)
5859
if: github.ref != 'refs/heads/main'
59-
working-directory: docs
6060
env:
6161
JEKYLL_ENV: preview
62-
BUNDLE_GEMFILE: ${{github.workspace}}/docs/GemFile
6362
run: bundle exec jekyll build
6463

6564
- name: Publish to Cloudflare Pages

.github/workflows/test-indicators-coverage.yml renamed to .github/workflows/test-code-coverage.yml

Lines changed: 16 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,22 @@
1-
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python
1+
# For more information see:
2+
# https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python
23

3-
name: Test with code coverage
4+
name: Test code coverage
45

5-
on: ["push"]
6+
on:
7+
push:
8+
branches: ["main"]
9+
pull_request:
10+
branches: ["*"]
11+
workflow_dispatch:
612

713
permissions:
814
contents: read
915

1016
jobs:
1117
test:
1218
name: indicators
13-
runs-on: macos-latest
19+
runs-on: ubuntu-latest
1420

1521
steps:
1622
- name: Checkout source
@@ -19,25 +25,24 @@ jobs:
1925
- name: Setup .NET
2026
uses: actions/setup-dotnet@v4
2127
with:
22-
dotnet-version: 8.x
23-
dotnet-quality: "ga"
28+
dotnet-version: 9.x
29+
dotnet-quality: ga
2430

2531
- name: Setup Python
2632
uses: actions/setup-python@v5
2733
with:
2834
python-version: 3.12
35+
cache: "pip"
2936

30-
- name: Install requirements
37+
- name: Install dependencies
3138
run: |
39+
pip install -U --upgrade-strategy=only-if-needed pip
3240
pip install -r requirements.txt
3341
pip install -r requirements-test.txt
3442
3543
- name: Test indicators
3644
run: |
37-
sed -i '' 's/export\ LC_ALL=en_US.UTF-8/export\ LC_ALL=ru_RU.UTF-8/g' ~/.bashrc
38-
source ~/.bashrc
39-
locale
40-
coverage run -m --source=stock_indicators pytest -svr A tests
45+
coverage run -m --source=stock_indicators pytest
4146
coverage xml
4247
4348
- name: Publish coverage to Codacy

.github/workflows/test-docs-a11y.yml

Lines changed: 0 additions & 62 deletions
This file was deleted.

.github/workflows/test-docs-links.yml

Lines changed: 0 additions & 81 deletions
This file was deleted.

.github/workflows/test-indicators-all-env.yml

Lines changed: 0 additions & 55 deletions
This file was deleted.

0 commit comments

Comments
 (0)