Skip to content

Commit

Permalink
Remove translations from Core (home-assistant#87543)
Browse files Browse the repository at this point in the history
Co-authored-by: Erik Montnemery <[email protected]>
  • Loading branch information
frenck and emontnemery authored Feb 6, 2023
1 parent 4ad386d commit 939eef3
Show file tree
Hide file tree
Showing 18,029 changed files with 100 additions and 510,450 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
4 changes: 4 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -848,6 +848,10 @@ jobs:
- name: Register pytest slow test problem matcher
run: |
echo "::add-matcher::.github/workflows/matchers/pytest-slow.json"
- name: Compile English translations
run: |
. venv/bin/activate
python3 -m script.translations develop --all
- name: Run pytest (fully)
if: needs.info.outputs.test_full_suite == 'true'
timeout-minutes: 60
Expand Down
65 changes: 0 additions & 65 deletions .github/workflows/translations.yaml

This file was deleted.

32 changes: 32 additions & 0 deletions .github/workflows/translations.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Translations

# yamllint disable-line rule:truthy
on:
workflow_dispatch:
push:
branches:
- dev
paths:
- "**strings.json"

env:
DEFAULT_PYTHON: "3.10"

jobs:
upload:
name: Upload
if: github.repository_owner == 'home-assistant'
runs-on: ubuntu-latest
steps:
- name: Checkout the repository
uses: actions/[email protected]

- name: Set up Python ${{ env.DEFAULT_PYTHON }}
uses: actions/[email protected]
with:
python-version: ${{ env.DEFAULT_PYTHON }}

- name: Upload Translations
run: |
export LOKALISE_TOKEN="${{ secrets.LOKALISE_TOKEN }}"
python3 -m script.translations upload
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ tests/testing_config/home-assistant.log*
data/
.token

# Translations
homeassistant/components/*/translations

# Hide sublime text stuff
*.sublime-project
*.sublime-workspace
Expand Down
6 changes: 4 additions & 2 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,17 @@
"request": "launch",
"module": "homeassistant",
"justMyCode": false,
"args": ["--debug", "-c", "config"]
"args": ["--debug", "-c", "config"],
"preLaunchTask": "Compile English translations"
},
{
"name": "Home Assistant (skip pip)",
"type": "python",
"request": "launch",
"module": "homeassistant",
"justMyCode": false,
"args": ["--debug", "-c", "config", "--skip-pip"]
"args": ["--debug", "-c", "config", "--skip-pip"],
"preLaunchTask": "Compile English translations"
},
{
// Debug by attaching to local Home Asistant server using Remote Python Debugger.
Expand Down
14 changes: 5 additions & 9 deletions .vscode/tasks.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@
"reveal": "always",
"panel": "new"
},
"problemMatcher": []
"problemMatcher": [],
"dependsOn": ["Compile English translations"]
},
{
"label": "Pytest",
Expand Down Expand Up @@ -142,19 +143,14 @@
"problemMatcher": []
},
{
"label": "Compile translations",
"label": "Compile English translations",
"detail": "In order to test changes to translation files, the translation strings must be compiled into Home Assistant's translation directories.",
"type": "shell",
"command": "python3 -m script.translations develop --integration ${input:integrationName}",
"command": "python3 -m script.translations develop --all",
"group": {
"kind": "build",
"isDefault": true
},
"presentation": {
"reveal": "always",
"panel": "new"
},
"problemMatcher": []
}
}
],
"inputs": [
Expand Down
26 changes: 0 additions & 26 deletions homeassistant/components/abode/translations/bg.json

This file was deleted.

35 changes: 0 additions & 35 deletions homeassistant/components/abode/translations/ca.json

This file was deleted.

35 changes: 0 additions & 35 deletions homeassistant/components/abode/translations/cs.json

This file was deleted.

16 changes: 0 additions & 16 deletions homeassistant/components/abode/translations/da.json

This file was deleted.

35 changes: 0 additions & 35 deletions homeassistant/components/abode/translations/de.json

This file was deleted.

35 changes: 0 additions & 35 deletions homeassistant/components/abode/translations/el.json

This file was deleted.

Loading

0 comments on commit 939eef3

Please sign in to comment.