Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
le5
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Harbor Registry
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Linux Educacional 5
le5
Commits
774bc1ac
Commit
774bc1ac
authored
10 years ago
by
Diego Giovane Pasqualin
Browse files
Options
Downloads
Patches
Plain Diff
le-greeter: Only divert files when needed
Signed-off-by:
Diego Giovane Pasqualin
<
dpasqualin@c3sl.ufpr.br
>
parent
16e40001
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
le-greeter/package/DEBIAN/control
+1
-1
1 addition, 1 deletion
le-greeter/package/DEBIAN/control
le-greeter/package/DEBIAN/preinst
+16
-4
16 additions, 4 deletions
le-greeter/package/DEBIAN/preinst
with
17 additions
and
5 deletions
le-greeter/package/DEBIAN/control
+
1
−
1
View file @
774bc1ac
Package: le-greeter
Priority: important
Section: main
Version: 0.1.3
7
Version: 0.1.3
8
Maintainer: LE Maintainer <le-maintainer@c3sl.ufpr.br>
Description: Login screen theme and configurations for Linux Educacional 5.0
Architecture: i386
...
...
This diff is collapsed.
Click to expand it.
le-greeter/package/DEBIAN/preinst
+
16
−
4
View file @
774bc1ac
...
...
@@ -24,17 +24,29 @@
RMDIVERTS
=
"/etc/lightdm/lightdm.conf"
DIVERTS
=
"/usr/sbin/guest-account"
# Check whether file $1 was already diverted.
# Return true if it was and false otherwise.
function
alreadyDiverted
()
{
file
=
"
$1
"
dpkg-divert
--listpackage
$file
|
grep
-q
le-greeter
return
$?
}
# Remove diverts made from previous versions of le-greeter (<0.1.36)
for
file
in
$RMDIVERTS
;
do
dpkg-divert
--remove
${
file
}
if
test
-e
${
file
}
.lightdm
;
then
rm
-f
${
file
}
.lightdm
if
alreadyDiverted
$file
;
then
dpkg-divert
--remove
${
file
}
if
test
-e
${
file
}
.lightdm
;
then
rm
-f
${
file
}
.lightdm
fi
fi
done
# Divert files:
for
file
in
$DIVERTS
;
do
dpkg-divert
--divert
${
file
}
.lightdm
--rename
${
file
}
if
!
alreadyDiverted
$file
;
then
dpkg-divert
--divert
${
file
}
.real
--rename
${
file
}
fi
done
exit
0
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