kuro: init at 9.0.0
Co-Authored-By: Nick Cao <nickcao@nichi.co> Co-Authored-By: ocfox <ocfox@outlook.com> Co-Authored-By: zendo <linzway@qq.com>
This commit is contained in:
parent
fd82d2bf83
commit
76fc5cb1e4
85
pkgs/applications/misc/kuro/default.nix
Normal file
85
pkgs/applications/misc/kuro/default.nix
Normal file
|
@ -0,0 +1,85 @@
|
||||||
|
{ lib
|
||||||
|
, fetchFromGitHub
|
||||||
|
, makeWrapper
|
||||||
|
, makeDesktopItem
|
||||||
|
, copyDesktopItems
|
||||||
|
, mkYarnPackage
|
||||||
|
, electron
|
||||||
|
}:
|
||||||
|
|
||||||
|
mkYarnPackage rec {
|
||||||
|
pname = "kuro";
|
||||||
|
version = "9.0.0";
|
||||||
|
|
||||||
|
src = fetchFromGitHub {
|
||||||
|
owner = "davidsmorais";
|
||||||
|
repo = pname;
|
||||||
|
rev = "v${version}";
|
||||||
|
sha256 = "sha256-9Z/r5T5ZI5aBghHmwiJcft/x/wTRzDlbIupujN2RFfU=";
|
||||||
|
};
|
||||||
|
|
||||||
|
packageJSON = ./package.json;
|
||||||
|
yarnLock = ./yarn.lock;
|
||||||
|
yarnNix = ./yarn.nix;
|
||||||
|
|
||||||
|
ELECTRON_SKIP_BINARY_DOWNLOAD = "1";
|
||||||
|
|
||||||
|
nativeBuildInputs = [
|
||||||
|
makeWrapper
|
||||||
|
copyDesktopItems
|
||||||
|
];
|
||||||
|
|
||||||
|
postBuild = ''
|
||||||
|
pushd deps/kuro
|
||||||
|
|
||||||
|
yarn --offline run electron-builder \
|
||||||
|
--dir \
|
||||||
|
-c.electronDist=${electron}/lib/electron \
|
||||||
|
-c.electronVersion=${electron.version}
|
||||||
|
|
||||||
|
popd
|
||||||
|
'';
|
||||||
|
|
||||||
|
installPhase = ''
|
||||||
|
runHook preInstall
|
||||||
|
|
||||||
|
# resources
|
||||||
|
mkdir -p "$out/share/lib/kuro"
|
||||||
|
cp -r ./deps/kuro/dist/*-unpacked/{locales,resources{,.pak}} "$out/share/lib/kuro"
|
||||||
|
|
||||||
|
# icons
|
||||||
|
install -Dm644 ./deps/kuro/static/Icon.png $out/share/icons/hicolor/1024x1024/apps/kuro.png
|
||||||
|
|
||||||
|
# executable wrapper
|
||||||
|
makeWrapper '${electron}/bin/electron' "$out/bin/kuro" \
|
||||||
|
--add-flags "$out/share/lib/kuro/resources/app.asar" \
|
||||||
|
--add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" \
|
||||||
|
--inherit-argv0
|
||||||
|
|
||||||
|
runHook postInstall
|
||||||
|
'';
|
||||||
|
# Do not attempt generating a tarball for contents again.
|
||||||
|
# note: `doDist = false;` does not work.
|
||||||
|
distPhase = "true";
|
||||||
|
|
||||||
|
desktopItems = [
|
||||||
|
(makeDesktopItem {
|
||||||
|
name = pname;
|
||||||
|
exec = pname;
|
||||||
|
icon = pname;
|
||||||
|
desktopName = "Kuro";
|
||||||
|
genericName = "Microsoft To-Do Client";
|
||||||
|
comment = meta.description;
|
||||||
|
categories = [ "Office" ];
|
||||||
|
startupWMClass = pname;
|
||||||
|
})
|
||||||
|
];
|
||||||
|
|
||||||
|
meta = with lib; {
|
||||||
|
description = "An unofficial, featureful, open source, community-driven, free Microsoft To-Do app";
|
||||||
|
homepage = "https://github.com/davidsmorais/kuro";
|
||||||
|
license = licenses.mit;
|
||||||
|
maintainers = with maintainers; [ ChaosAttractor ];
|
||||||
|
inherit (electron.meta) platforms;
|
||||||
|
};
|
||||||
|
}
|
149
pkgs/applications/misc/kuro/package.json
Normal file
149
pkgs/applications/misc/kuro/package.json
Normal file
|
@ -0,0 +1,149 @@
|
||||||
|
{
|
||||||
|
"name": "kuro",
|
||||||
|
"productName": "Kuro",
|
||||||
|
"version": "9.0.0",
|
||||||
|
"description": "Elegant Microsoft To-Do desktop app (Ao fork)",
|
||||||
|
"license": "MIT",
|
||||||
|
"repository": "davidsmorais/kuro",
|
||||||
|
"author": {
|
||||||
|
"name": "davidsmorais",
|
||||||
|
"email": "david@dsmorais.com",
|
||||||
|
"url": "https://github.com/davidsmorais"
|
||||||
|
},
|
||||||
|
"maintainers": [
|
||||||
|
{
|
||||||
|
"name": "davidsmorais",
|
||||||
|
"email": "david@dsmorais.com",
|
||||||
|
"url": "https://github.com/davidsmorais"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"scripts": {
|
||||||
|
"postinstall": "electron-builder install-app-deps",
|
||||||
|
"icons": "electron-icon-maker --input=./static/Icon.png --output=./build/",
|
||||||
|
"test": "xo && stylelint 'src/style/*.css'",
|
||||||
|
"release": "yarn version && rm -rf dist build && yarn icons && electron-builder --publish never",
|
||||||
|
"build-snap": "electron-builder --linux snap",
|
||||||
|
"build-win": "electron-builder --win",
|
||||||
|
"start": "electron ."
|
||||||
|
},
|
||||||
|
"dependencies": {
|
||||||
|
"auto-launch": "^5.0.1",
|
||||||
|
"electron-context-menu": "^3.6.1",
|
||||||
|
"electron-debug": "^1.4.0",
|
||||||
|
"electron-dl": "^2.0.0",
|
||||||
|
"electron-store": "^8.1.0",
|
||||||
|
"lodash": "^4.17.21"
|
||||||
|
},
|
||||||
|
"devDependencies": {
|
||||||
|
"electron": "^22.1.0",
|
||||||
|
"electron-builder": "^23.6.0",
|
||||||
|
"electron-icon-maker": "^0.0.5",
|
||||||
|
"stylelint": "^14.9.1",
|
||||||
|
"xo": "^0.53.1"
|
||||||
|
},
|
||||||
|
"xo": {
|
||||||
|
"envs": [
|
||||||
|
"browser",
|
||||||
|
"node"
|
||||||
|
],
|
||||||
|
"rules": {
|
||||||
|
"n/prefer-global/process": 0,
|
||||||
|
"unicorn/prefer-module": 0,
|
||||||
|
"unicorn/no-for-loop": 0,
|
||||||
|
"unicorn/no-array-for-each": 0,
|
||||||
|
"import/extensions": 0,
|
||||||
|
"object-curly-spacing": 0,
|
||||||
|
"quote-props": 0,
|
||||||
|
"unicorn/prefer-query-selector": 0,
|
||||||
|
"quotes": [
|
||||||
|
"error",
|
||||||
|
"double"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"space": 2
|
||||||
|
},
|
||||||
|
"stylelint": {
|
||||||
|
"rules": {
|
||||||
|
"block-closing-brace-empty-line-before": "never",
|
||||||
|
"block-closing-brace-newline-after": "always",
|
||||||
|
"block-no-empty": true,
|
||||||
|
"block-opening-brace-space-before": "always",
|
||||||
|
"color-hex-case": "upper",
|
||||||
|
"color-hex-length": "long",
|
||||||
|
"color-no-invalid-hex": true,
|
||||||
|
"comment-no-empty": true,
|
||||||
|
"declaration-block-semicolon-space-before": "never",
|
||||||
|
"indentation": 2,
|
||||||
|
"max-empty-lines": 0,
|
||||||
|
"no-duplicate-selectors": true
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"build": {
|
||||||
|
"appId": "com.davidsmorais.kuro",
|
||||||
|
"snap": {
|
||||||
|
"title": "Kuro"
|
||||||
|
},
|
||||||
|
"files": [
|
||||||
|
"**/*",
|
||||||
|
"!media${/*}",
|
||||||
|
"!docs${/*}"
|
||||||
|
],
|
||||||
|
"win": {
|
||||||
|
"target": [
|
||||||
|
{
|
||||||
|
"target": "nsis",
|
||||||
|
"arch": [
|
||||||
|
"x64"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"icon": "icons/win/icon.ico",
|
||||||
|
"publish": {
|
||||||
|
"provider": "github",
|
||||||
|
"releaseType": "release"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"linux": {
|
||||||
|
"category": "Office",
|
||||||
|
"icon": "icons/png",
|
||||||
|
"description": "Kuro is an unofficial, featureful, open source, community-driven, free Microsoft To-Do app, used by people in more than 120 countries. (Ao fork)",
|
||||||
|
"synopsis": "Elegant Microsoft To-Do desktop app (Ao fork)",
|
||||||
|
"publish": {
|
||||||
|
"provider": "github",
|
||||||
|
"releaseType": "release"
|
||||||
|
},
|
||||||
|
"target": [
|
||||||
|
{
|
||||||
|
"target": "AppImage",
|
||||||
|
"arch": [
|
||||||
|
"x64"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"target": "deb",
|
||||||
|
"arch": [
|
||||||
|
"x64"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"target": "pacman",
|
||||||
|
"arch": [
|
||||||
|
"x64"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"target": "rpm",
|
||||||
|
"arch": [
|
||||||
|
"x64"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"target": "snap",
|
||||||
|
"arch": [
|
||||||
|
"x64"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
5757
pkgs/applications/misc/kuro/yarn.lock
Normal file
5757
pkgs/applications/misc/kuro/yarn.lock
Normal file
File diff suppressed because it is too large
Load diff
6485
pkgs/applications/misc/kuro/yarn.nix
Normal file
6485
pkgs/applications/misc/kuro/yarn.nix
Normal file
File diff suppressed because it is too large
Load diff
|
@ -30482,6 +30482,10 @@ with pkgs;
|
||||||
|
|
||||||
kupfer = callPackage ../applications/misc/kupfer { };
|
kupfer = callPackage ../applications/misc/kupfer { };
|
||||||
|
|
||||||
|
kuro = callPackage ../applications/misc/kuro {
|
||||||
|
electron = electron_22;
|
||||||
|
};
|
||||||
|
|
||||||
kvirc = libsForQt5.callPackage ../applications/networking/irc/kvirc { };
|
kvirc = libsForQt5.callPackage ../applications/networking/irc/kvirc { };
|
||||||
|
|
||||||
lame = callPackage ../development/libraries/lame { };
|
lame = callPackage ../development/libraries/lame { };
|
||||||
|
|
Loading…
Reference in a new issue