Commit Graph

141 Commits (main)

Author SHA1 Message Date
Noah Hsu b50d486a63 fix: sub path check if subPath = `/` 2022-12-18 21:28:38 +08:00
foxxorcat 6024e8d832
refactor: split the db package hook and cache to the op package (#2747)
* refactor:separate the setting method from the db package to the op package and add the cache

* refactor:separate the meta method from the db package to the op package

* fix:setting not load database data

* refactor:separate the user method from the db package to the op package

* refactor:remove user JoinPath error

* fix:op package user cache

* refactor:fs package list method

* fix:tile virtual paths (close #2743)

* Revert "refactor:remove user JoinPath error"

This reverts commit 4e20daaf9e.

* clean path directly may lead to unknown behavior

* fix: The path of the meta passed in must be prefix of reqPath

* chore: rename all virtualPath to mountPath

* fix: `getStoragesByPath` and `GetStorageVirtualFilesByPath`

is_sub_path:

/a/b isn't subpath of /a/bc

* fix: don't save setting if hook error

Co-authored-by: Noah Hsu <i@nn.ci>
2022-12-18 19:51:20 +08:00
foxxorcat fb64f00640
refactor: obj name mapping and internal path processing (#2733)
* refactor:Prepare to remove the get interface

* feat:add obj Unwarp interface

* refactor:obj name mapping and program internal path processing

* chore: fix typo

* feat: unwrap get

* fix: no use op.Get to get parent id

* fix: set the path uniformly

Co-authored-by: Noah Hsu <i@nn.ci>
2022-12-17 19:49:05 +08:00
Noah Hsu 5043815d48 fix(search): don't delete virtual folder while update indexes (close #2677) 2022-12-11 14:59:58 +08:00
BoYanZh 6f1aeb47fd
feat: index enhancement (close #2632 pr #2636)
* feat: index paths as setting

* feat: clear index (#2632)

* feat: check indexMQ more frequently
2022-12-09 10:02:13 +08:00
Noah Hsu bd33c200dc feat: optimize index build 2022-12-05 16:07:36 +08:00
Noah Hsu bc6baf1be0 fix(ci): sort lang json file 2022-12-05 14:40:46 +08:00
Noah Hsu 18a63e34dd fix(task): memory alignment for curID (close #2541) 2022-12-01 13:16:31 +08:00
Noah Hsu b5bf5f4325 fix: check if the req path is relative path (close #2531) 2022-11-30 21:38:00 +08:00
SiHuaN f9788ea7cf
feat(webdav): delete privacy header and optimize 302 (#2534)
* fix: delete set-cookie from sharepoint webdav response header

* fix: avoid two redirects when using webdav

* fix: return the correct Content-Type instead of just `application/octet-stream`

* feat: webdav backend localOnly -> proxyOnly
2022-11-30 20:52:33 +08:00
Noah Hsu 83644dab85 fix: mapping filename in `GetName`
some missed filename mapping
2022-11-30 20:46:54 +08:00
Noah Hsu 76f37373e0 fix: settings map read and write concurrently 2022-11-28 16:54:03 +08:00
Noah Hsu ddcba93eea
feat: multiple search indexes (#2514)
* refactor: abstract search interface

* wip: ~

* fix cycle import

* objs update hook

* wip: ~

* Delete search/none

* auto update index while cache changed

* db searcher

TODO: bleve init issue

cannot open index, metadata missing

* fix size type

why float64??

* fix typo

* fix nil pointer using

* api adapt ui

* bleve: fix clear & change struct
2022-11-28 13:45:25 +08:00
Noah Hsu c09800790b feat: custom filename char mapping
fixes #2447 #2446 #2440 #2409 #2006 #1979 #1507 #324 #691 #518 #430
2022-11-22 15:54:18 +08:00
Code2qing c601bb794b
feat(123): support mail login (close #2218 pr #2276) 2022-11-10 09:34:48 +08:00
Noah Hsu f3a5e3702d fix(189): force use `CN` time zone (close #2240) 2022-11-07 16:37:47 +08:00
BoYanZh f0cc0a76a9
chore: fix typos (#2122)
* refactor: fix typos

* Update help.go

Co-authored-by: Noah Hsu <i@nn.ci>
2022-10-26 14:05:56 +08:00
Noah Hsu 8c69260972 fix(webdav): set mime by ext if it's empty 2022-10-09 19:29:55 +08:00
Noah Hsu dcaaae366b feat: add support for mega.nz (close 1553) 2022-10-08 22:16:41 +08:00
Noah Hsu 2185839236 chore: safe base64 decode ipa name 2022-09-18 20:17:24 +08:00
Noah Hsu 6c89c6c8ae fix: aria2 download magnet link (close #1665) 2022-09-18 16:07:32 +08:00
Noah Hsu d9f0603271 fix: copy folder between two storage (fix #1670) 2022-09-15 17:58:32 +08:00
Noah Hsu b197322cd8 fix: type of file with name uppercase 2022-09-14 15:14:04 +08:00
Noah Hsu 9e5ef974a7 fix: send on closed channel 2022-09-14 15:13:02 +08:00
foxxorcat 6b5236f52e feat: add baidu_photo driver 2022-09-12 17:10:02 +08:00
Noah Hsu 043a79189d style: uniform use `utils.CreateTempFile` 2022-09-10 14:11:06 +08:00
Noah Hsu 5ed43fd17d fix(123): pass ip when getting download link 2022-09-10 13:54:10 +08:00
Noah Hsu fbaebc020f fix(189pc): wrong time if location incorrect (close #1562) 2022-09-08 20:03:07 +08:00
Noah Hsu 534d8d30fc feat: skip generate lang if no changes 2022-09-05 16:40:51 +08:00
Noah Hsu 900e71f78f feat: add `139yun` driver 2022-09-05 13:35:01 +08:00
Noah Hsu 3dd4fbd76d feat: add webdav driver 2022-09-04 22:34:54 +08:00
Noah Hsu dcc99802ec fix: panic while create empty file 2022-09-03 19:32:44 +08:00
Noah Hsu decea4a739 feat: add quark driver 2022-09-02 21:36:47 +08:00
Noah Hsu 2d2a4f5776 docs: add go report card [skip ci] 2022-09-01 22:49:47 +08:00
Noah Hsu 454f563bce fix: task id not update 2022-08-31 22:53:41 +08:00
Noah Hsu 755f4b83f6 feat: add progress for io copy 2022-08-31 22:41:27 +08:00
Noah Hsu 817d63597e feat: add aliyundrive driver 2022-08-31 20:46:19 +08:00
Noah Hsu a6b9dbfbe4 fix: use `utils.Log` in some places 2022-08-30 16:13:01 +08:00
Noah Hsu 046bbb3a48 feat: use `lumberjack` for log rotate 2022-08-30 15:22:54 +08:00
Noah Hsu cc9ccc4e9b ci: auto generate drivers lang file 2022-08-26 19:06:32 +08:00
Noah Hsu 7425e001db feat: auto generate drivers language json 2022-08-26 15:08:31 +08:00
Noah Hsu d9ee174dd3 feat!: unity iframe preview 2022-08-23 16:50:54 +08:00
Noah Hsu af884010d1 feat: local storage image thumbnail 2022-08-11 20:32:17 +08:00
Noah Hsu 61fa6f38a8 feat: add type to fs read api 2022-08-08 00:51:05 +08:00
Noah Hsu cb06d3a19a feat: remove and clear task 2022-07-31 21:21:54 +08:00
Noah Hsu be452aafde chore: fix err nil pointer 2022-07-30 22:04:21 +08:00
Noah Hsu b399c924b7 chore: slice convert util 2022-07-27 17:08:29 +08:00
Noah Hsu 90a5c175ed feat: virtual driver 2022-07-19 19:55:54 +08:00
Noah Hsu b1d563c874 chore: add uuid to token 2022-07-12 14:01:43 +08:00
Noah Hsu fc1204c914 chore: rename account to storage 2022-07-10 14:45:39 +08:00
Noah Hsu 2b1726614b feat: webdav handle 2022-06-30 22:41:55 +08:00
Noah Hsu e614faa99b chore: cancel task while wait for worker 2022-06-29 22:06:56 +08:00
Noah Hsu f54418bdae fix: serialize task info 2022-06-29 20:28:02 +08:00
Noah Hsu 0bf724f447 feat: task manage api 2022-06-29 18:36:14 +08:00
Noah Hsu 8a0915ffb1 chore: don't and slash prefix just for windows abs path 2022-06-28 22:22:02 +08:00
Noah Hsu 67bc66fedf feat: file down handle 2022-06-28 18:00:11 +08:00
Noah Hsu d89ec89d51 feat: sign of file 2022-06-28 15:12:40 +08:00
Noah Hsu 5dbf5db4ff feat: token and reset 2022-06-28 14:18:10 +08:00
Noah Hsu db6b5f8950 chore: path standardize 2022-06-27 20:56:17 +08:00
Noah Hsu 74973bc5b5 fix: local relative path 2022-06-27 20:37:05 +08:00
Noah Hsu 4cef3adc90 feat: meta manage api 2022-06-26 19:09:28 +08:00
Noah Hsu c5295f4d72 feat: user jwt login 2022-06-25 21:34:44 +08:00
Noah Hsu 306b90399c chore: move conf package 2022-06-25 20:38:02 +08:00
Noah Hsu ee2bc99e4c feat: cancel copy for upload 2022-06-25 15:14:03 +08:00
Noah Hsu 92983aa185 chore: get or remove by states 2022-06-23 21:19:01 +08:00
Noah Hsu 6c61f1d261 chore: add state for task 2022-06-23 21:09:54 +08:00
Noah Hsu ffa0bc294a chore: optimize standardize path 2022-06-23 17:04:37 +08:00
Noah Hsu 3fe0a7bf6b refactor(task): remove `Data` field 2022-06-22 19:28:41 +08:00
Noah Hsu f6242d46b1 feat: add uri to aria2 2022-06-21 17:37:02 +08:00
Noah Hsu 55d6434daa refactor(task): generic task manager 2022-06-21 16:14:37 +08:00
Noah Hsu 6c552a9d62 chore: aria2 related function 2022-06-20 20:34:58 +08:00
Noah Hsu 31ff31d3dd chore: add callback for task 2022-06-20 17:13:19 +08:00
Noah Hsu d665cce739 feat: add task work limit 2022-06-18 20:38:14 +08:00
Noah Hsu adf0178bb7 feat: add progress for task 2022-06-18 20:06:45 +08:00
Noah Hsu 6ad2cf2003 test: add task manager test 2022-06-17 22:09:34 +08:00
Noah Hsu 68ca2abd0c chore: change task.ID to uint64 2022-06-17 21:52:31 +08:00
Noah Hsu fa6e918fc7 feat: add copy to task manager 2022-06-17 21:23:44 +08:00
Noah Hsu 2cddd3cf2b chore: add aria2 rpc package 2022-06-15 17:15:22 +08:00
Noah Hsu c65a9b3001 fix: typo 2022-06-15 14:57:13 +08:00
Noah Hsu 066ddd3e09 chore: create temp file util 2022-06-15 14:56:43 +08:00
Noah Hsu 5780d9d834 test: add `GetAccountVirtualFilesByPath` test 2022-06-14 22:23:33 +08:00
Noah Hsu 7c4d28d55a feat: replace with generic_sync.MapOf 2022-06-14 19:09:54 +08:00
Noah Hsu 6056fdbddc feat: use singleflight to prevent cache breakdown 2022-06-13 20:24:13 +08:00
Noah Hsu 3e8f36e9f3 feat: get root folder file 2022-06-13 14:53:44 +08:00
Noah Hsu 77b0c69112 feat: extract get function 2022-06-11 14:43:03 +08:00
Noah Hsu 7b6f11fa52 feat: get account by path 2022-06-10 16:49:52 +08:00
Noah Hsu 164dab49ac feat: get accounts by path 2022-06-09 23:05:27 +08:00
Noah Hsu fced60c2b5 feat: basic structure 2022-06-06 21:48:53 +08:00
Noah Hsu b76060570e refactor: init v3 2022-06-06 16:28:37 +08:00
Xhofe 42c0e438d5 fix(webdav): sharepoint upload 2022-04-24 15:38:17 +08:00
Xhofe 27b7dae113 feat(webdav): support range get 2022-04-23 22:43:02 +08:00