Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
pmbootstrap
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Robert Eckelmann
pmbootstrap
Commits
01faedcf
Unverified
Commit
01faedcf
authored
2 months ago
by
Newbyte
Committed by
Oliver Smith
2 months ago
Browse files
Options
Downloads
Patches
Plain Diff
pmb.types: Fix type for PmbArgs.output (MR 2522)
And remove hack needed to accomodate this wrong type.
parent
8e09be57
No related branches found
No related tags found
No related merge requests found
Pipeline
#213758
failed
2 months ago
Stage: test
Stage: deploy
Stage: integration-test
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
pmb/helpers/frontend.py
+4
-7
4 additions, 7 deletions
pmb/helpers/frontend.py
pmb/types.py
+1
-1
1 addition, 1 deletion
pmb/types.py
with
5 additions
and
8 deletions
pmb/helpers/frontend.py
+
4
−
7
View file @
01faedcf
...
...
@@ -7,7 +7,7 @@ from pmb.helpers import logging
import
os
from
pathlib
import
Path
import
sys
from
typing
import
cast
,
Any
,
NoReturn
from
typing
import
Any
,
NoReturn
import
pmb.aportgen
import
pmb.build
...
...
@@ -19,7 +19,7 @@ import pmb.chroot.other
import
pmb.ci
import
pmb.config
from
pmb.core
import
Config
from
pmb.types
import
Env
,
PmbArgs
,
RunOutputType
from
pmb.types
import
Env
,
PmbArgs
import
pmb.export
import
pmb.flasher
import
pmb.helpers.aportupgrade
...
...
@@ -213,16 +213,13 @@ def chroot(args: PmbArgs) -> None:
pmb
.
helpers
.
apk
.
update_repository_list
(
chroot
.
path
,
user_repository
=
True
)
# TODO: Maybe this could be done better.
output_type
=
cast
(
RunOutputType
,
args
.
output
)
# Run the command as user/root
if
user
:
logging
.
info
(
f
"
(
{
chroot
}
) % su pmos -c
'"
+
"
"
.
join
(
args
.
command
)
+
"'"
)
pmb
.
chroot
.
user
(
args
.
command
,
chroot
,
output
=
output
_type
,
env
=
env
)
pmb
.
chroot
.
user
(
args
.
command
,
chroot
,
output
=
args
.
output
,
env
=
env
)
else
:
logging
.
info
(
f
"
(
{
chroot
}
) %
"
+
"
"
.
join
(
args
.
command
))
pmb
.
chroot
.
root
(
args
.
command
,
chroot
,
output
=
output
_type
,
env
=
env
)
pmb
.
chroot
.
root
(
args
.
command
,
chroot
,
output
=
args
.
output
,
env
=
env
)
def
config
(
args
:
PmbArgs
)
->
None
:
...
...
This diff is collapsed.
Click to expand it.
pmb/types.py
+
1
−
1
View file @
01faedcf
...
...
@@ -143,7 +143,7 @@ class PmbArgs(Namespace):
on_device_installer
:
bool
ondev_cp
:
list
[
tuple
[
str
,
str
]]
ondev_no_rootfs
:
bool
output
:
str
output
:
RunOutputType
overview
:
bool
# FIXME (#2324): figure out the args.package vs args.packages situation
package
:
str
|
list
[
str
]
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment