File tree 6 files changed +168
-1
lines changed
Filter options
6 files changed +168
-1
lines changed
Original file line number Diff line number Diff line change
1
+ use flake
Original file line number Diff line number Diff line change @@ -183,3 +183,5 @@ core/js/mimetypelist.js
183
183
cypress /downloads
184
184
cypress /snapshots
185
185
cypress /videos
186
+
187
+ /.direnv
Original file line number Diff line number Diff line change @@ -351,6 +351,6 @@ Files: apps/theming/fonts/OpenDyslexic-Bold.otf apps/theming/fonts/OpenDyslexic-
351
351
Copyright: 2012-2019 Abbie Gonzalez <https://abbiecod.es|support@abbiecod.es>, with Reserved Font Name OpenDyslexic.
352
352
License: OFL-1.1-RFN
353
353
354
- Files: openapi.json
354
+ Files: openapi.json .envrc flake.nix flake.lock
355
355
Copyright: 2025 Nextcloud GmbH and Nextcloud contributors
356
356
License: AGPL-3.0-or-later
Original file line number Diff line number Diff line change 11
11
'.. ' ,
12
12
'.devcontainer ' ,
13
13
'.editorconfig ' ,
14
+ '.envrc ' ,
14
15
'.eslintignore ' ,
15
16
'.eslintrc.js ' ,
16
17
'.git ' ,
61
62
'cypress.d.ts ' ,
62
63
'cypress ' ,
63
64
'dist ' ,
65
+ 'flake.lock ' ,
66
+ 'flake.nix ' ,
64
67
'index.html ' ,
65
68
'index.php ' ,
66
69
'lib ' ,
Original file line number Diff line number Diff line change
1
+ {
2
+ inputs = {
3
+ nixpkgs . url = "github:nixos/nixpkgs/nixos-24.11" ;
4
+ flake-utils . url = "github:numtide/flake-utils" ;
5
+ } ;
6
+
7
+ outputs = { nixpkgs , flake-utils , ... } :
8
+ flake-utils . lib . eachDefaultSystem ( system :
9
+ let
10
+ pkgs = nixpkgs . legacyPackages . ${ system } ;
11
+ lib = pkgs . lib ;
12
+ in
13
+ {
14
+ devShells . default =
15
+ let
16
+ php_versioncheck_parts = builtins . match ".*PHP_VERSION_ID >= ([0-9])0([0-9])00.*" ( builtins . readFile ./lib/versioncheck.php ) ;
17
+ # Subtract 1 from the lowest unsupported minor version to get the highest supported minor version
18
+ php_version = "${ builtins . elemAt php_versioncheck_parts 0 } ${ builtins . toString ( ( lib . strings . toInt ( builtins . elemAt php_versioncheck_parts 1 ) ) - 1 ) } " ;
19
+ php = pkgs . pkgs . "php${ php_version } " . buildEnv {
20
+ # Based off https://docs.nextcloud.com/server/latest/admin_manual/installation/php_configuration.html
21
+ extensions = ( { enabled , all } : enabled ++ ( with all ; [
22
+ # Required
23
+ ctype
24
+ curl
25
+ dom
26
+ fileinfo
27
+ filter
28
+ gd
29
+ mbstring
30
+ openssl
31
+ posix
32
+ session
33
+ simplexml
34
+ xmlreader
35
+ xmlwriter
36
+ zip
37
+ zlib
38
+ # Database connectors
39
+ pdo_sqlite
40
+ pdo_mysql
41
+ pdo_pgsql
42
+ # Recommended
43
+ intl
44
+ sodium
45
+ # Required for specific apps
46
+ ldap
47
+ smbclient
48
+ ftp
49
+ imap
50
+ # Recommended for specific apps (optional)
51
+ gmp
52
+ exif
53
+ # For enhanced server performance (optional)
54
+ apcu
55
+ memcached
56
+ redis
57
+ # For preview generation (optional)
58
+ imagick
59
+ # For command line processing (optional)
60
+ pcntl
61
+
62
+ # Debugging
63
+ xdebug
64
+ ] ) ) ;
65
+
66
+ extraConfig = ''
67
+ max_execution_time=300
68
+ memory_limit=-1
69
+
70
+ xdebug.mode=debug
71
+ '' ;
72
+ } ;
73
+ # Skip the caret and only take the major version
74
+ node_version = builtins . substring 1 2 ( builtins . fromJSON ( builtins . readFile ./package.json ) ) . engines . node ;
75
+ node = pkgs . "nodejs_${ node_version } " ;
76
+ in
77
+ pkgs . mkShell {
78
+ packages = [
79
+ php
80
+ php . packages . composer
81
+ node
82
+ # Preview generation
83
+ pkgs . ffmpeg
84
+ pkgs . libreoffice
85
+ ] ;
86
+
87
+ shellHook = ''
88
+ export NOCOVERAGE=1
89
+
90
+ git submodule update --init
91
+
92
+ npm install
93
+
94
+ composer install
95
+ cd build/integration && composer install
96
+ '' ;
97
+ } ;
98
+ }
99
+ ) ;
100
+ }
You can’t perform that action at this time.
0 commit comments