Skip to content

Commit

Permalink
Remove .client from the main desktop file name
Browse files Browse the repository at this point in the history
This syncs with Flatpak usage, allowing the use of a single desktop file name
on all platform. (Flatpak is very opinionated.) This will be useful to set the
desktop file name on the QApplication.

Related to #2019, #984.
  • Loading branch information
lmoureaux committed Dec 26, 2023
1 parent a396561 commit ca5de9d
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 11 deletions.
12 changes: 6 additions & 6 deletions cmake/FreecivInstall.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -171,21 +171,21 @@ if(UNIX AND NOT APPLE)

# Install MetaInfo and Desktop files for the applications asked for at configure
if(FREECIV_ENABLE_CLIENT)
configure_file(${CMAKE_SOURCE_DIR}/dist/net.longturn.freeciv21.client.desktop.in
net.longturn.freeciv21.client.desktop
configure_file(${CMAKE_SOURCE_DIR}/dist/net.longturn.freeciv21.desktop.in
net.longturn.freeciv21.desktop
@ONLY NEWLINE_STYLE UNIX)
configure_file(${CMAKE_SOURCE_DIR}/dist/net.longturn.freeciv21.client.metainfo.xml.in
net.longturn.freeciv21.client.metainfo.xml
configure_file(${CMAKE_SOURCE_DIR}/dist/net.longturn.freeciv21.metainfo.xml.in
net.longturn.freeciv21.metainfo.xml
@ONLY NEWLINE_STYLE UNIX)
install(
FILES
${CMAKE_BINARY_DIR}/net.longturn.freeciv21.client.desktop
${CMAKE_BINARY_DIR}/net.longturn.freeciv21.desktop
DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/applications
COMPONENT freeciv21
)
install(
FILES
${CMAKE_BINARY_DIR}/net.longturn.freeciv21.client.metainfo.xml
${CMAKE_BINARY_DIR}/net.longturn.freeciv21.metainfo.xml
DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/metainfo
COMPONENT freeciv21
)
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<component type="desktop-application">
<id type="desktop">net.longturn.freeciv21.client</id>
<id type="desktop">net.longturn.freeciv21</id>
<metadata_license>CC0</metadata_license>
<project_license>GPL-3.0+</project_license>
<name>Freeciv21 Client</name>
Expand All @@ -11,7 +11,7 @@
<p>Freeciv21 takes its roots in the well-known FOSS game Freeciv and extends it for more fun, with a revived focus on competitive multiplayer environments. Players can choose from over 500 nations and can play against the computer or other people in an active online community.</p>
<p>The code is maintained by the team over at Longturn.net and is based on the QT framework. The game supports both hex and square tiles and is easily modified to create custom rules.</p>
</description>
<launchable type="desktop-id">net.longturn.freeciv21.client.desktop</launchable>
<launchable type="desktop-id">net.longturn.freeciv21.desktop</launchable>
<icon type="remote">https://raw.githubusercontent.com/longturn/freeciv21/master/data/icons/128x128/freeciv21-client.png</icon>
<url type="homepage">https://longturn.net/</url>
<url type="bugtracker">https://github.com/longturn/freeciv21/issues</url>
Expand Down
6 changes: 3 additions & 3 deletions dist/snapcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -79,15 +79,15 @@ parts:
- libsdl2-mixer-2.0-0
- libsqlite3-0
parse-info:
- usr/share/metainfo/net.longturn.freeciv21.client.metainfo.xml
- usr/share/metainfo/net.longturn.freeciv21.metainfo.xml
- usr/share/metainfo/net.longturn.freeciv21.modpack.metainfo.xml
- usr/share/metainfo/net.longturn.freeciv21.ruledit.metainfo.xml
- usr/share/metainfo/net.longturn.freeciv21.server.metainfo.xml

apps:
freeciv21-client:
common-id: net.longturn.freeciv21.client
desktop: usr/share/applications/net.longturn.freeciv21.client.desktop
common-id: net.longturn.freeciv21
desktop: usr/share/applications/net.longturn.freeciv21.desktop
command: usr/bin/freeciv21-client
extensions:
- kde-neon
Expand Down

0 comments on commit ca5de9d

Please sign in to comment.