Skip to content

Commit 04d2107

Browse files
authored
Codebase Rework
2 parents 98c55c6 + ce96246 commit 04d2107

File tree

159 files changed

+4264
-32323
lines changed

Some content is hidden

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

159 files changed

+4264
-32323
lines changed

.config/Tasks/Release-Locales.sh

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
#!/usr/bin/env bash
2+
3+
set -euo pipefail
4+
5+
6+
release='/usr/lib/qt6/bin/lrelease'
7+
8+
output='freecad/plot/Resources/Locales'
9+
input='Resources/Locales'
10+
11+
12+
releaseLocale (){
13+
14+
local file=$1
15+
16+
local source="${input}/${file}.ts"
17+
local target="${output}/Plot_${file}.qm"
18+
19+
"$release" \
20+
-nounfinished \
21+
"${source}" \
22+
-qm "${target}"
23+
}
24+
25+
26+
releaseLocale 'ja'

.config/Tasks/Update-Locales.sh

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
#!/usr/bin/env bash
2+
3+
set -euo pipefail
4+
5+
6+
update='/usr/lib/qt6/bin/lupdate'
7+
8+
output='Resources/Locales'
9+
10+
11+
files=($( find "freecad" -name "*.ui" -o -name "*.py" ))
12+
13+
14+
updateLocale (){
15+
16+
local locale=$1
17+
18+
local file="${output}/${locale}.ts"
19+
20+
"$update" "${files[@]}" \
21+
-source-language en_US \
22+
-target-language "${locale}" \
23+
-no-obsolete \
24+
-ts "${file}"
25+
}
26+
27+
28+
updateLocale 'ja'

.editorconfig

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,14 +48,14 @@
4848
root = true
4949

5050

51-
[*.{toml,xml,py,md}]
51+
[*.{toml,xml,py,md,svg}]
5252
insert_final_newline = false
5353
indent_style = space
5454
end_of_line = lf
5555
indent_size = 4
5656
charset = utf-8
5757

58-
[*.{toml,xml,py}]
58+
[*.{toml,xml,py,svg}]
5959
trim_trailing_whitespace = true
6060

6161
[*.{md}]

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,3 +92,6 @@ ENV/
9292

9393
# Rope project settings
9494
.ropeproject
95+
96+
97+
freecad/plot/Resources/Interface/*.py
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
# SPDX-License-Identifier: LGPL-2.1-or-later
22

3-
__version__ = "0.0.2"
3+
# Stub file to shut the pre-commit hook up!

.vscode/settings.json

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
{
2+
"qtForPython.uic.liveExecution.enabled" : false ,
3+
4+
"files.associations" : {
5+
"**/Resources/Locales/*.ts": "xml",
6+
"LICENSE-*" : "txt"
7+
},
8+
9+
"search.exclude" : {
10+
"uv.lock" : true
11+
}
12+
}

LICENSE renamed to LICENSE-CODE

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@
66
Everyone is permitted to copy and distribute verbatim copies
77
of this license document, but changing it is not allowed.
88

9-
(This is the first released version of the Lesser GPL. It also counts
9+
[This is the first released version of the Lesser GPL. It also counts
1010
as the successor of the GNU Library Public License, version 2, hence
11-
the version number 2.1.)
11+
the version number 2.1.]
1212

1313
Preamble
1414

@@ -470,8 +470,8 @@ safest to attach them to the start of each source file to most effectively
470470
convey the exclusion of warranty; and each file should have at least the
471471
"copyright" line and a pointer to where the full notice is found.
472472

473-
{description}
474-
Copyright (C) {year} {fullname}
473+
<one line to give the library's name and a brief idea of what it does.>
474+
Copyright (C) <year> <name of author>
475475

476476
This library is free software; you can redistribute it and/or
477477
modify it under the terms of the GNU Lesser General Public
@@ -498,8 +498,7 @@ necessary. Here is a sample; alter the names:
498498
library `Frob' (a library for tweaking knobs) written by James Random
499499
Hacker.
500500

501-
{signature of Ty Coon}, 1 April 1990
501+
<signature of Ty Coon>, 1 April 1990
502502
Ty Coon, President of Vice
503503

504-
That's all there is to it!
505-
504+
That's all there is to it!

0 commit comments

Comments
 (0)