Skip to content

Commit 6de2f92

Browse files
committed
Initial version
0 parents  commit 6de2f92

File tree

19 files changed

+775
-0
lines changed

19 files changed

+775
-0
lines changed

.gitattributes

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# Set default behaviour, in case users don't have core.autocrlf set.
2+
* text=auto
3+
4+
# Try to ensure that po files in the repo does not include
5+
# source code line numbers.
6+
# Every person expected to commit po files should change their personal config file as described here:
7+
# https://mail.gnome.org/archives/kupfer-list/2010-June/msg00002.html
8+
*.po filter=cleanpo
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: CustomAppModuleMapperPrValidation
2+
on:
3+
pull_request:
4+
types: [opened, synchronize, reopened]
5+
jobs:
6+
Validate_PR:
7+
runs-on: "ubuntu-latest"
8+
steps:
9+
- name: Checkout code
10+
uses: actions/checkout@v3
11+
- name: install system dependencies
12+
run: |
13+
sudo apt update
14+
sudo apt install -y gettext
15+
- name: Install python
16+
uses: actions/setup-python@v4
17+
with:
18+
# it seems that x86 versions of python 3 are not available for linux install.
19+
# In this addon context it is really not important, as packaging should not deppend on architecture versions
20+
# However, for future NVDA related actions we might have to switch to windows runners
21+
python-version: "3.11"
22+
- name: install python dependencies
23+
run: |
24+
pip install scons
25+
pip install markdown
26+
pip install pre-commit
27+
- name: validate pr
28+
run: |
29+
pre-commit run --all-files
Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
name: CustomAppModuleMapperCI
2+
on:
3+
push:
4+
tags:
5+
- "**"
6+
jobs:
7+
Release_addon:
8+
runs-on: "ubuntu-latest"
9+
steps:
10+
- name: Checkout code
11+
uses: actions/checkout@v3
12+
# The next step is used to fix a small issue here to obtain the current tag message, which will be used as the release body. For more details
13+
# see https://github.com/actions/checkout/issues/290
14+
- name: make sure we have the correct tag information
15+
run: git fetch --tags --force
16+
- name: Obtain tag message
17+
uses: ericcornelissen/git-tag-annotation-action@v2
18+
id: tag-data
19+
- name: Check differences to main branch
20+
id: differences-to-main
21+
run: |
22+
if git diff origin/main --exit-code; then
23+
echo "::set-output name=changes_exist::false"
24+
else
25+
echo "::set-output name=changes_exist::true"
26+
fi
27+
- name: abort if tag is not applied on top of main
28+
if: ${{ steps.differences-to-main.outputs.changes_exist == 'true' }}
29+
uses: actions/github-script@v3
30+
with:
31+
script: |
32+
core.setFailed('Releases can be generated only from commit on head of main branch')
33+
- name: install system dependencies
34+
run: |
35+
sudo apt update
36+
sudo apt install -y gettext
37+
- name: Install python
38+
uses: actions/setup-python@v4
39+
with:
40+
# it seems that x86 versions of python 3 are not available for linux install.
41+
# In this addon context it is really not important, as packaging should not deppend on architecture versions
42+
# However, for future NVDA related actions we might have to switch to windows runners
43+
python-version: "3.11"
44+
- name: install python dependencies
45+
run: |
46+
pip install scons
47+
pip install markdown
48+
pip install pre-commit
49+
- name: validate addon
50+
run: |
51+
pre-commit run --all-files
52+
- name: build addon
53+
run: |
54+
rm -f *.nvda-addon || true
55+
scons
56+
- name: Release addon
57+
uses: softprops/action-gh-release@v2
58+
with:
59+
files: "*.nvda-addon"
60+
body: "${{ steps.tag-data.outputs.git-tag-annotation }}"
61+
fail_on_unmatched_files: true
62+
generate_release_notes: false

.gitignore

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
addon/doc/*.css
2+
addon/doc/**/*.md
3+
!addon/doc/**/contributing.md
4+
!addon/doc/**/*.tpl.md
5+
*_docHandler.py
6+
*.html
7+
*.ini
8+
!flake8.ini
9+
*.mo
10+
*.pot
11+
*.py[co]
12+
*.nvda-addon
13+
.sconsign.dblite

.pre-commit-config.yaml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
repos:
2+
- repo: https://github.com/pre-commit/pre-commit-hooks
3+
rev: v4.3.0
4+
hooks:
5+
- id: check-ast
6+
- id: check-case-conflict
7+
- id: check-yaml
8+
- repo: https://github.com/PyCQA/flake8
9+
rev: 4.0.1
10+
hooks:
11+
- id: flake8
12+
args: [--config=flake8.ini]

.vscode/extensions.json

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
// See https://go.microsoft.com/fwlink/?LinkId=827846 to learn about workspace recommendations.
3+
// Extension identifier format: ${publisher}.${name}. Example: vscode.csharp
4+
// List of extensions which should be recommended for users of this workspace.
5+
"recommendations": [
6+
"ms-python.python",
7+
"ms-python.vscode-pylance",
8+
"redhat.vscode-yaml",
9+
"ms-python.flake8"
10+
],
11+
// List of extensions recommended by VS Code that should not be recommended for users of this workspace.
12+
"unwantedRecommendations": []
13+
}

.vscode/settings.json

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
{
2+
"editor.accessibilitySupport": "on",
3+
"flake8.args": [
4+
"--config=flake8.ini"
5+
],
6+
"flake8.importStrategy": "fromEnvironment",
7+
"python.autoComplete.extraPaths": [
8+
"../nvda/source",
9+
"../nvda/miscDeps/python"
10+
],
11+
"files.insertFinalNewline": true,
12+
"files.trimFinalNewlines": true,
13+
"editor.insertSpaces": false,
14+
"python.analysis.stubPath": "${workspaceFolder}/.vscode/typings",
15+
"python.analysis.extraPaths": [
16+
"../nvda/source",
17+
"../nvda/miscDeps/python"
18+
],
19+
"python.defaultInterpreterPath": "${workspaceFolder}/../nvda/.venv/scripts/python.exe"
20+
}

.vscode/typings/__builtins__.pyi

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
def _(msg: str) -> str:
2+
...
3+
4+
5+
def pgettext(context: str, message: str) -> str:
6+
...

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2020 Marlon Brandão de Sousa
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# CustomAppModulesMapper 0.1.0
2+
3+
Nvda ADDON for allowing dynamic mapping of existing app modules for other applications.
4+
5+
## download
6+
Download the [CustomAppModulesMapper 0.1.0 addon](https://github.com/marlon-sousa/CustomAppModulesMapper/releases/download/0.1.0/CustomAppModulesMapper-0.1.0.nvda-addon)
7+
8+
## Features
9+
10+
To be documented.

0 commit comments

Comments
 (0)