Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Appimage #3374

Closed
wants to merge 9 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .envrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
use_nix
use flake;
3 changes: 2 additions & 1 deletion .github/workflows/Linux-pack.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
push:
branches:
- master
- main
paths-ignore:
- 'README.md'
- 'LICENSE'
Expand Down Expand Up @@ -417,7 +418,7 @@ jobs:
mkdir -p "${APPIMAGE_DST_PATH}"

cd $GITHUB_WORKSPACE
cmake -S . -B build -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_INSTALL_PREFIX="/usr/${APPIMAGE_DST_PATH}" -DUSE_LAUNCHER_ABSOLUTE_PATH:BOOL=OFF
cmake -S . -B build -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_INSTALL_PREFIX="${APPIMAGE_DST_PATH}/usr" -DUSE_LAUNCHER_ABSOLUTE_PATH:BOOL=OFF
cmake --build build --target install --config RelWithDebInfo -- -j$(nproc)


Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/MacOS-pack.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Packaging(MacOS)
on:
push:
branches:
- master
- main
- feature/RND-680-macos-.dmg-package-build
paths-ignore:
- 'README.md'
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/Windows-pack.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
push:
branches:
- master*
- main*
paths-ignore:
- 'README.md'
- 'LICENSE'
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/build_cmake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@ name: Building(CMake)

on:
push:
branches: [ master ]
branches: [ master, main ]
paths-ignore:
- 'README.md'
- 'LICENSE'
pull_request:
branches: [ master ]
branches: [ master, main ]
paths-ignore:
- 'README.md'
- 'LICENSE'
Expand Down
75 changes: 0 additions & 75 deletions .github/workflows/deploy-dev-docs.yml

This file was deleted.

5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,11 @@ data/flatpak/.flatpak-builder

# End of https://www.gitignore.io/api/snapcraft

#MacOS Crap
# MacOS
.DS_Store

# Miscellaneous
!docs/dev/Makefile
# Nix
result
.direnv/
6 changes: 1 addition & 5 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
cmake_minimum_required(VERSION 3.13)
# cmake_policy(SET CMP0076 OLD)

set(FLAMESHOT_VERSION 12.1.0)
set(FLAMESHOT_VERSION 13.0.0)

# Flameshot-org
set(GIT_API_URL "https://api.github.com/repos/flameshot-org/flameshot/releases/latest")
Expand Down Expand Up @@ -68,10 +68,6 @@ option(GENERATE_TS "Regenerate translation source files" OFF)
option(USE_EXTERNAL_SINGLEAPPLICATION "Use external QtSingleApplication library" OFF)
option(USE_LAUNCHER_ABSOLUTE_PATH "Use absolute path for the desktop launcher" ON)
option(USE_WAYLAND_CLIPBOARD "USE KF Gui Wayland Clipboard" OFF)
option(DISABLE_UPDATE_CHECKER "Disable check for updates" OFF)
if (DISABLE_UPDATE_CHECKER)
add_compile_definitions(DISABLE_UPDATE_CHECKER)
endif ()

include(cmake/StandardProjectSettings.cmake)

Expand Down
36 changes: 36 additions & 0 deletions default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
{
stdenv,
lib,
libsForQt5,
wrapQtAppsHook,
cmake,
qtbase,
qttools,
qtsvg,
}:
with libsForQt5;
stdenv.mkDerivation rec {
pname = "flameshot";
version = "0.3.0";

src = ./.;

nativeBuildInputs = [
cmake
qttools
qtsvg
wrapQtAppsHook
];
buildInputs = [qtbase];

cmakeFlags = [
];

meta = with lib; {
homepage = "";
description = ''
'';
licencse = licenses.gpl3Plus;
platforms = with platforms; linux ++ darwin;
};
}
61 changes: 61 additions & 0 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

39 changes: 39 additions & 0 deletions flake.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
{
description = "Flameshot flake build";

inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/22.11";

utils.url = "github:numtide/flake-utils";
utils.inputs.nixpkgs.follows = "nixpkgs";
};

outputs = { self, nixpkgs, ... }@inputs: inputs.utils.lib.eachSystem [
"x86_64-linux" "i686-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin"
] (system: let pkgs = import nixpkgs {
inherit system;
};
in {
devShell = pkgs.mkShell rec {
name = "flameshot";

packages = with pkgs; [
# Development Tools
cmake
cmakeCurses
libsForQt5.qt5.qttools
qt5.wrapQtAppsHook

# Dependencies
libsForQt5.qt5.qtsvg
libsForQt5.qt5.qtbase
];
};
defaultPackage = pkgs.callPackage ./default.nix {
qtbase = pkgs.libsForQt5.qt5.qtbase;
qttools = pkgs.libsForQt5.qt5.qttools;
qtsvg = pkgs.libsForQt5.qt5.qtsvg;
wrapQtAppsHook = pkgs.qt5.wrapQtAppsHook;
};
});
}
11 changes: 0 additions & 11 deletions shell.nix

This file was deleted.

3 changes: 0 additions & 3 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ find_package(
Core
Gui
Widgets
Network
Svg
DBus
LinguistTools)
Expand Down Expand Up @@ -158,7 +157,6 @@ target_include_directories(
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/tools/circlecount>
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/tools/copy>
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/tools/exit>
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/tools/imgur>
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/tools/launcher>
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/tools/line>
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/tools/marker>
Expand Down Expand Up @@ -202,7 +200,6 @@ target_link_libraries(
project_options
Qt5::Svg
Qt5::DBus
Qt5::Network
Qt5::Widgets
${QTSINGLEAPPLICATION_LIBRARY}
QtColorWidgets
Expand Down
Loading
Loading