-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use uyuni-releng-tools to push the package to OBS
- Loading branch information
Showing
7 changed files
with
70 additions
and
22 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 |
---|---|---|
@@ -1,3 +1,6 @@ | ||
.idea/ | ||
rhn.conf | ||
inter-server-sync | ||
vendor.tar.gz | ||
*.pyc | ||
__pycache__ |
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,30 @@ | ||
# Copyright (c) 2018 SUSE Linux Products GmbH | ||
# SPDX-FileCopyrightText: 2023 SUSE LLC | ||
# | ||
# SPDX-License-Identifier: GPL-2.0-only | ||
|
||
""" | ||
Code for building packages in SUSE that need generated code not tracked in git. | ||
""" | ||
import os | ||
|
||
from tito.builder import Builder | ||
from tito.common import info_out, run_command | ||
|
||
class SuseGitExtraGenerationBuilder(Builder): | ||
|
||
def _setup_sources(self): | ||
|
||
Builder._setup_sources(self) | ||
setup_execution_file_name = "setup.sh" | ||
setup_file_dir = os.path.join(self.git_root, self.relative_project_dir) | ||
setup_file_path = os.path.join(setup_file_dir, setup_execution_file_name) | ||
if os.path.exists(setup_file_path): | ||
info_out("Executing %s" % setup_file_path) | ||
output = run_command("[[ -x %s ]] && %s" % (setup_file_path, setup_file_path), True) | ||
filename = output.split('\n')[-1] | ||
if filename and os.path.exists(os.path.join(setup_file_dir, filename)): | ||
info_out("Copying %s to %s" % (os.path.join(setup_file_dir, filename), self.rpmbuild_sourcedir)) | ||
run_command("cp %s %s/" % (os.path.join(setup_file_dir, filename), self.rpmbuild_sourcedir), True) | ||
self.sources.append(os.path.join(self.rpmbuild_sourcedir, filename)) | ||
|
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,7 @@ | ||
[buildconfig] | ||
builder = custom.SuseGitExtraGenerationBuilder | ||
tagger = tito.tagger.SUSETagger | ||
changelog_with_email = 0 | ||
changelog_do_not_remove_cherrypick = 0 | ||
no_default_changelog = 1 | ||
lib_dir=.tito/custom |
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
- Use tito to push to OBS and help releasing |
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 |
---|---|---|
@@ -0,0 +1,9 @@ | ||
# SPDX-FileCopyrightText: 2023 SUSE LLC | ||
# | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
set -euxo pipefail | ||
|
||
go mod vendor && tar czvf vendor.tar.gz vendor >/dev/null && rm -rf vendor | ||
|
||
echo "vendor.tar.gz" |