Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Csuper
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
Operations
Operations
Incidents
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Dalan94
Csuper
Commits
7f9fa714
Verified
Commit
7f9fa714
authored
Nov 01, 2017
by
Rémi BERTHO
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Improve utility.sh
parent
cac0fcc4
Changes
7
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
611 additions
and
703 deletions
+611
-703
Man/csuper-cli.1.gz
Man/csuper-cli.1.gz
+0
-0
Man/csuper-gtk.1.gz
Man/csuper-gtk.1.gz
+0
-0
Translations/csuper-cli/messages.pot
Translations/csuper-cli/messages.pot
+1
-1
Translations/csuper-gtk/fr.po
Translations/csuper-gtk/fr.po
+281
-325
Translations/csuper-gtk/messages.pot
Translations/csuper-gtk/messages.pot
+281
-325
Translations/libcsuper/messages.pot
Translations/libcsuper/messages.pot
+1
-1
utility.sh
utility.sh
+47
-51
No files found.
Man/csuper-cli.1.gz
View file @
7f9fa714
No preview for this file type
Man/csuper-gtk.1.gz
View file @
7f9fa714
No preview for this file type
Translations/csuper-cli/messages.pot
View file @
7f9fa714
...
...
@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-01 1
1:03
+0100\n"
"POT-Creation-Date: 2017-11-01 1
4:30
+0100\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
...
...
Translations/csuper-gtk/fr.po
View file @
7f9fa714
This diff is collapsed.
Click to expand it.
Translations/csuper-gtk/messages.pot
View file @
7f9fa714
This diff is collapsed.
Click to expand it.
Translations/libcsuper/messages.pot
View file @
7f9fa714
...
...
@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-01 1
1:03
+0100\n"
"POT-Creation-Date: 2017-11-01 1
4:30
+0100\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
...
...
utility.sh
View file @
7f9fa714
...
...
@@ -35,35 +35,35 @@ print_help()
update_man
()
{
echo
"Update man pages"
cd
"
$dir
/Man"
cd
"
Man"
||
return
pandoc
-s
-t
man csuper-cli.1.md
-o
csuper-cli.1
gzip
-f
csuper-cli.1
pandoc
-s
-t
man csuper-gtk.1.md
-o
csuper-gtk.1
gzip
-f
csuper-gtk.1
cd
"
$dir
"
cd
..
||
return
}
update_translation
()
{
echo
"Update translations"
xgettext
--sort-by-file
--add-comments
=
TRANSLATORS:
--keyword
=
_
-o
$dir
/
Translations/libcsuper/messages.pot Sources/libcsuper/
*
.cpp
xgettext
--sort-by-file
--add-comments
=
TRANSLATORS:
--keyword
=
_
-o
$dir
/
Translations/csuper-cli/messages.pot Sources/csuper-cli/
*
.cpp
xgettext
--sort-by-file
--add-comments
=
TRANSLATORS:
--keyword
=
translatable
--keyword
=
_
-o
$dir
/Translations/csuper-gtk/messages.pot
$dir
/Sources/csuper-gtk/
*
.cpp
$dir
/
UI/csuper-gtk.glade
xgettext
--sort-by-file
--add-comments
=
TRANSLATORS:
--keyword
=
_
-o
Translations/libcsuper/messages.pot Sources/libcsuper/
*
.cpp
xgettext
--sort-by-file
--add-comments
=
TRANSLATORS:
--keyword
=
_
-o
Translations/csuper-cli/messages.pot Sources/csuper-cli/
*
.cpp
xgettext
--sort-by-file
--add-comments
=
TRANSLATORS:
--keyword
=
translatable
--keyword
=
_
-o
Translations/csuper-gtk/messages.pot Sources/csuper-gtk/
*
.cpp
UI/csuper-gtk.glade
for
i
in
"
$dir
/Translations/libcsuper/*.po"
for
i
in
Translations/libcsuper/
*
.po
do
msgmerge
-U
$i
"
$dir
/
Translations/libcsuper/messages.pot"
msgmerge
-U
$i
"Translations/libcsuper/messages.pot"
done
for
i
in
"
$dir
/Translations/csuper-cli/*.po"
for
i
in
Translations/csuper-cli/
*
.po
do
msgmerge
-U
$i
"
$dir
/
Translations/csuper-cli/messages.pot"
msgmerge
-U
$i
"Translations/csuper-cli/messages.pot"
done
for
i
in
"
$dir
/Translations/csuper-gtk/*.po"
for
i
in
Translations/csuper-gtk/
*
.po
do
msgmerge
-U
$i
"
$dir
/
Translations/csuper-gtk/messages.pot"
msgmerge
-U
$i
"Translations/csuper-gtk/messages.pot"
done
}
...
...
@@ -71,59 +71,59 @@ compile_translation()
{
echo
"Compile translations"
mkdir
-p
Locales/fr_FR/LC_MESSAGES
msgfmt
"
$dir
/Translations/libcsuper/fr.po"
-o
"
$dir
/
Locales/fr_FR/LC_MESSAGES/libcsuper.mo"
msgfmt
"
$dir
/Translations/csuper-cli/fr.po"
-o
"
$dir
/
Locales/fr_FR/LC_MESSAGES/csuper-cli.mo"
msgfmt
"
$dir
/Translations/csuper-gtk/fr.po"
-o
"
$dir
/
Locales/fr_FR/LC_MESSAGES/csuper-gtk.mo"
msgfmt
"
Translations/libcsuper/fr.po"
-o
"
Locales/fr_FR/LC_MESSAGES/libcsuper.mo"
msgfmt
"
Translations/csuper-cli/fr.po"
-o
"
Locales/fr_FR/LC_MESSAGES/csuper-cli.mo"
msgfmt
"
Translations/csuper-gtk/fr.po"
-o
"
Locales/fr_FR/LC_MESSAGES/csuper-gtk.mo"
}
generate_documentation
()
{
echo
"Generate documentation"
cd
"
$dir
/Documentation"
cd
"
Documentation"
||
return
doxygen libcsuper_doxyfile &> /dev/null
doxygen csuper-cli_doxyfile &> /dev/null
doxygen csuper-gtk_doxyfile &> /dev/null
cd
"
$dir
"
cd
..
||
return
}
compile_pdf_doc
()
{
echo
"Compile PDF documentation"
cd
"
$dir
/Documentation/libcsuper/latex"
cd
"
Documentation/libcsuper/latex"
||
return
make &> /dev/null
cd
../../csuper-cli/latex
cd
../../csuper-cli/latex
||
return
make &> /dev/null
cd
../../csuper-gtk/latex
cd
../../csuper-gtk/latex
||
return
make &> /dev/null
cd
"
$dir
"
cd
../../..
||
return
}
format_code
()
{
echo
"Format code"
clang-format
-style
=
file
$dir
/
Sources/libcsuper/
*
.cpp
-i
clang-format
-style
=
file
$dir
/
Sources/libcsuper/
*
.h
-i
clang-format
-style
=
file
$dir
/
Sources/csuper-cli/
*
.cpp
-i
clang-format
-style
=
file
$dir
/
Sources/csuper-cli/
*
.h
-i
clang-format
-style
=
file
$dir
/
Sources/csuper-gtk/
*
.cpp
-i
clang-format
-style
=
file
$dir
/
Sources/csuper-gtk/
*
.h
-i
clang-format
-style
=
file Sources/libcsuper/
*
.cpp
-i
clang-format
-style
=
file Sources/libcsuper/
*
.h
-i
clang-format
-style
=
file Sources/csuper-cli/
*
.cpp
-i
clang-format
-style
=
file Sources/csuper-cli/
*
.h
-i
clang-format
-style
=
file Sources/csuper-gtk/
*
.cpp
-i
clang-format
-style
=
file Sources/csuper-gtk/
*
.h
-i
}
install_libcsuper
()
{
echo
"Install libcsuper"
sudo mkdir
-p
/usr/share/csuper/Locales/fr_FR/LC_MESSAGES
sudo cp
$dir
/
libcsuper.so /usr/lib
sudo cp
$dir
/
Locales/fr_FR/LC_MESSAGES/libcsuper.mo /usr/share/csuper/Locales/fr_FR/LC_MESSAGES/libcsuper.mo
sudo cp
libcsuper.so /usr/lib
sudo cp
Locales/fr_FR/LC_MESSAGES/libcsuper.mo /usr/share/csuper/Locales/fr_FR/LC_MESSAGES/libcsuper.mo
sudo mkdir
-p
/usr/include/libcsuper
sudo cp
$dir
/
Sources/libcsuper/
*
.h /usr/include/libcsuper
sudo cp
-R
$dir
/
Images /usr/share/csuper
sudo cp
Sources/libcsuper/
*
.h /usr/include/libcsuper
sudo cp
-R
Images /usr/share/csuper
sudo
update-mime-database usr/share/mime &> /dev/null
sudo cp
$dir
/
Installation/Mime/csuper.xml /usr/share/mime/packages/
sudo cp
$dir
/
Installation/Mime/application-csu.png /usr/share/icons/hicolor/48x48/mimetypes
sudo cp
Installation/Mime/csuper.xml /usr/share/mime/packages/
sudo cp
Installation/Mime/application-csu.png /usr/share/icons/hicolor/48x48/mimetypes
sudo
ldconfig
}
...
...
@@ -131,10 +131,10 @@ install_csuper_cli()
{
echo
"Install csuper-cli"
sudo mkdir
-p
/usr/share/csuper/Locales/fr_FR/LC_MESSAGES
sudo cp
$dir
/
csuper-cli /usr/share/csuper
sudo cp
-R
$dir
/
Locales/fr_FR/LC_MESSAGES/csuper-cli.mo /usr/share/csuper/Locales/fr_FR/LC_MESSAGES
sudo cp
$dir
/
Installation/csuper-cli /usr/bin/csuper-cli
sudo cp
$dir
/
Man/csuper-cli.1.gz /usr/share/man/man1
sudo cp
csuper-cli /usr/share/csuper
sudo cp
-R
Locales/fr_FR/LC_MESSAGES/csuper-cli.mo /usr/share/csuper/Locales/fr_FR/LC_MESSAGES
sudo cp
Installation/csuper-cli /usr/bin/csuper-cli
sudo cp
Man/csuper-cli.1.gz /usr/share/man/man1
sudo chmod
-R
a+rx /usr/share/csuper
}
...
...
@@ -142,16 +142,16 @@ install_csuper_gtk()
{
echo
"Install csuper-gtk"
sudo mkdir
-p
/usr/share/csuper/Locales/fr_FR/LC_MESSAGES
sudo cp
$dir
/
csuper-gtk /usr/share/csuper
sudo cp
-R
$dir
/
UI /usr/share/csuper
sudo cp
-R
$dir
/
Locales/fr_FR/LC_MESSAGES/csuper-gtk.mo /usr/share/csuper/Locales/fr_FR/LC_MESSAGES
sudo cp
$dir
/
Installation/csuper-gtk /usr/bin/csuper-gtk
sudo cp
$dir
/
Installation/csuper-html /usr/bin/csuper-html
sudo cp
$dir
/
Installation/csuper-html-autostart /usr/bin/csuper-html-autostart
sudo cp
$dir
/
Man/csuper-gtk.1.gz /usr/share/man/man1
sudo cp
$dir
/
Installation/fr.dalan.csuper-gtk.desktop /usr/share/applications/
sudo cp
$dir
/
Installation/fr.dalan.csuper-html.desktop /usr/share/applications/
sudo cp
$dir
/
Installation/csuper.service /etc/systemd/system/
sudo cp
csuper-gtk /usr/share/csuper
sudo cp
-R
UI /usr/share/csuper
sudo cp
-R
Locales/fr_FR/LC_MESSAGES/csuper-gtk.mo /usr/share/csuper/Locales/fr_FR/LC_MESSAGES
sudo cp
Installation/csuper-gtk /usr/bin/csuper-gtk
sudo cp
Installation/csuper-html /usr/bin/csuper-html
sudo cp
Installation/csuper-html-autostart /usr/bin/csuper-html-autostart
sudo cp
Man/csuper-gtk.1.gz /usr/share/man/man1
sudo cp
Installation/fr.dalan.csuper-gtk.desktop /usr/share/applications/
sudo cp
Installation/fr.dalan.csuper-html.desktop /usr/share/applications/
sudo cp
Installation/csuper.service /etc/systemd/system/
sudo chmod
-R
a+rx /usr/share/csuper
[[
-x
usr/bin/update-desktop-database
]]
&&
update-desktop-database
-q
||
true
}
...
...
@@ -193,11 +193,7 @@ uninstall_csuper_gtk()
sudo rm
/etc/systemd/system/csuper.service
}
if
[[
$2
==
""
]]
;
then
dir
=
$(
pwd
)
else
dir
=
$2
fi
cd
"
$(
dirname
"
${
BASH_SOURCE
[0]
}
"
)
"
||
exit
case
"
$1
"
in
"-h"
|
"--help"
)
...
...
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