Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
chromebrew
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
chromebrew
Commits
8eef57d0
Commit
8eef57d0
authored
May 05, 2016
by
Michał Siwek
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #166 from lyxell/disallow-sudo
Disallow sudo
parents
3cdbf3ba
db07c76a
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
0 deletions
+8
-0
crew
crew
+3
-0
install.sh
install.sh
+5
-0
No files found.
crew
View file @
8eef57d0
...
...
@@ -21,6 +21,9 @@ $LOAD_PATH.unshift "#{CREW_LIB_PATH}lib"
USER
=
`whoami`
.
chomp
#disallow sudo
abort
"Chromebrew should not be run as root."
if
Process
.
uid
==
0
&&
@command
!=
"remove"
@device
=
JSON
.
parse
(
File
.
read
(
CREW_CONFIG_PATH
+
'device.json'
),
symbolize_names:
true
)
#symbolize also values
@device
.
each
do
|
key
,
elem
|
...
...
install.sh
View file @
8eef57d0
...
...
@@ -13,6 +13,11 @@ CREW_PACKAGES_PATH=$CREW_LIB_PATH/packages
user
=
$(
whoami
)
architecture
=
$(
uname
-m
)
if
[
$EUID
-eq
0
]
;
then
echo
'Chromebrew should not be run as root.'
exit
1
;
fi
if
[
$architecture
!=
"i686"
]
&&
[
$architecture
!=
"x86_64"
]
;
then
echo
'Your device is not supported by Chromebrew yet.'
exit
1
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment