-
-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #88 from nixel2007/develop
Sync
- Loading branch information
Showing
9 changed files
with
568 additions
and
33 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -16,10 +16,10 @@ jobs: | |
os: [ubuntu-latest, windows-latest, macos-latest] | ||
oscript_version: ['1.8.3', 'stable'] | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Setup Onescript Action | ||
uses: otymko/setup-onescript@v1.1 | ||
uses: otymko/setup-onescript@v1.4 | ||
with: | ||
version: ${{ matrix.oscript_version }} | ||
|
||
|
@@ -28,22 +28,26 @@ jobs: | |
opm install [email protected] | ||
opm install -l --dev | ||
- name: Prepare macOS env | ||
if: matrix.os == 'macos-latest' | ||
run: | | ||
echo "SIGN_QEMU_BINARY=1" >> "$GITHUB_ENV" | ||
- name: Install docker | ||
if: matrix.os != 'windows-latest' | ||
uses: crazy-max/ghaction-setup-docker@v1 | ||
uses: crazy-max/ghaction-setup-docker@v3 | ||
timeout-minutes: 12 | ||
|
||
- name: Setup PostgreSQL | ||
if: matrix.os != 'windows-latest' | ||
shell: bash | ||
run: | | ||
docker run --rm --name postgres -d -p 5432:5432 -e POSTGRES_PASSWORD=postgres -e POSTGRES_USERNAME=postgres -e POSTGRES_DB=postgres -e POSTGRES_HOST_AUTH_METHOD=password --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 postgres | ||
docker run --rm --name postgres -d -p 5432:5432 -e POSTGRES_PASSWORD=postgres -e POSTGRES_USERNAME=postgres -e POSTGRES_DB=postgres -e POSTGRES_HOST_AUTH_METHOD=password --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 satrapu/postgresql | ||
docker ps | ||
while [ "`docker inspect -f {{.State.Health.Status}} postgres`" != "healthy" ]; do docker ps && sleep 2; done | ||
docker ps | ||
- name: Run tests | ||
env: | ||
TESTRUNNER_RUN_POSTGRES_TESTS: "${{ matrix.os != 'windows-latest' }}" | ||
TESTRUNNER_RUN_POSTGRES_TESTS: true | ||
TESTRUNNER_RUN_SQLITE_TESTS: "${{ matrix.os == 'windows-latest' }}" | ||
run: | | ||
oscript ./tasks/test.os |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,13 +9,13 @@ jobs: | |
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/checkout@v4 | ||
with: | ||
# Disabling shallow clone is recommended for improving relevancy of reporting | ||
fetch-depth: 0 | ||
|
||
- name: Setup Onescript Action | ||
uses: otymko/setup-onescript@v1.1 | ||
uses: otymko/setup-onescript@v1.4 | ||
with: | ||
version: "1.8.3" | ||
|
||
|
@@ -25,7 +25,7 @@ jobs: | |
opm install -l --dev | ||
- name: Install docker | ||
uses: crazy-max/ghaction-setup-docker@v1 | ||
uses: crazy-max/ghaction-setup-docker@v3 | ||
timeout-minutes: 12 | ||
|
||
- name: Setup PostgreSQL | ||
|
@@ -50,28 +50,30 @@ jobs: | |
run: | | ||
oscript ./tasks/coverage.os | ||
- name: SonarCloud Scan on push | ||
if: github.repository == 'nixel2007/entity' && github.event_name == 'push' | ||
uses: nixel2007/[email protected] | ||
- name: Setup sonarqube | ||
uses: warchant/setup-sonar-scanner@v8 | ||
|
||
# Анализ проекта в SonarQube (ветка) | ||
- name: Анализ в SonarQube (branch) | ||
if: github.event_name == 'push' | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} | ||
with: | ||
args: > | ||
-Dsonar.host.url=https://sonar.openbsl.ru | ||
-Dsonar.branch.name=${{ env.BRANCH_NAME }} | ||
-Dsonar.projectVersion=${{ steps.extract_version.outputs.version }} | ||
- name: SonarCloud Scan on PR | ||
if: github.repository == 'nixel2007/entity' && github.event_name == 'pull_request' | ||
uses: nixel2007/sonarcloud-github[email protected] | ||
run: sonar-scanner | ||
-Dsonar.host.url=https://sonar.openbsl.ru | ||
-Dsonar.branch.name=${{ env.BRANCH_NAME }} | ||
-Dsonar.projectVersion=${{ steps.extract_version.outputs.version }} | ||
|
||
# Анализ проекта в SonarQube (PR) | ||
# https://docs.sonarqube.org/latest/analysis/pull-request/ | ||
- name: Анализ в SonarQube (pull-request) | ||
if: github.event_name == 'pull_request' | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} | ||
with: | ||
args: > | ||
-Dsonar.host.url=https://sonar.openbsl.ru | ||
-Dsonar.pullrequest.key=${{ github.event.pull_request.number }} | ||
-Dsonar.pullrequest.branch=${{ github.event.pull_request.head.ref }} | ||
-Dsonar.pullrequest.base=${{ github.event.pull_request.base.ref }} | ||
-Dsonar.scm.revision=${{ github.event.pull_request.head.sha }} | ||
run: sonar-scanner | ||
-Dsonar.host.url=https://sonar.openbsl.ru | ||
-Dsonar.pullrequest.key=${{ github.event.pull_request.number }} | ||
-Dsonar.pullrequest.branch=${{ github.event.pull_request.head.ref }} | ||
-Dsonar.pullrequest.base=${{ github.event.pull_request.base.ref }} | ||
-Dsonar.scm.revision=${{ github.event.pull_request.head.sha }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,7 +4,7 @@ | |
// | ||
// BSLLS:CodeOutOfRegion-off | ||
Описание.Имя("entity") | ||
.Версия("2.3.5.0") | ||
.Версия("2.3.6.0") | ||
.Автор("Nikita Gryzlov") | ||
.АдресАвтора("[email protected]") | ||
.Описание("entity") | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
|
||
Перем КешиТаблиц; | ||
|
||
Функция КешТаблиц(СтрокаПодключения = "default") Экспорт | ||
Результат = КешиТаблиц.Получить(СтрокаПодключения); | ||
|
||
Если Результат = Неопределено Тогда | ||
Результат = Новый Соответствие(); | ||
КешиТаблиц.Вставить(СтрокаПодключения, Результат); | ||
КонецЕсли; | ||
|
||
Возврат Результат; | ||
|
||
КонецФункции | ||
|
||
Процедура Очистить(СтрокаПодключения = "default") Экспорт | ||
КешиТаблиц.Вставить(СтрокаПодключения, Новый Соответствие()); | ||
КонецПроцедуры | ||
|
||
Процедура Инициализация() | ||
КешиТаблиц = Новый Соответствие(); | ||
КонецПроцедуры | ||
|
||
Инициализация(); |
Oops, something went wrong.