mirror of
				https://github.com/9001/copyparty.git
				synced 2025-11-04 05:43:17 +00:00 
			
		
		
		
	add cygpath support for volume src too
This commit is contained in:
		@@ -301,7 +301,7 @@ note:
 | 
			
		||||
* `e2tsr` is probably always overkill, since `e2ds`/`e2dsa` would pick up any file modifications and cause `e2ts` to reindex those
 | 
			
		||||
* the rescan button in the admin panel has no effect unless the volume has `-e2ds` or higher
 | 
			
		||||
 | 
			
		||||
you can choose to only index filename/path/size/last-modified (and not the hash of the file contents) by setting `--no-hash` or the volume-flag `cnhash`, this has the following consequences:
 | 
			
		||||
you can choose to only index filename/path/size/last-modified (and not the hash of the file contents) by setting `--no-hash` or the volume-flag `cdhash`, this has the following consequences:
 | 
			
		||||
* initial indexing is way faster, especially when the volume is on a networked disk
 | 
			
		||||
* makes it impossible to [file-search](#file-search)
 | 
			
		||||
* if someone uploads the same file contents, the upload will not be detected as a dupe, so it will not get symlinked or rejected
 | 
			
		||||
@@ -319,6 +319,7 @@ this can instead be kept in a single place using the `--hist` argument, or the `
 | 
			
		||||
note:
 | 
			
		||||
* markdown edits are always stored in a local `.hist` subdirectory
 | 
			
		||||
* on windows the volflag path is cyglike, so `/c/temp` means `C:\temp` but use regular paths for `--hist`
 | 
			
		||||
  * you can use cygpaths for volumes too, `-v C:\Users::r` and `-v /c/users::r` both work
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
## metadata from audio files
 | 
			
		||||
 
 | 
			
		||||
@@ -439,6 +439,9 @@ class AuthSrv(object):
 | 
			
		||||
                    raise Exception("invalid -v argument: [{}]".format(v_str))
 | 
			
		||||
 | 
			
		||||
                src, dst, perms = m.groups()
 | 
			
		||||
                if WINDOWS and src.startswith("/"):
 | 
			
		||||
                    src = "{}:\\{}".format(src[1], src[3:])
 | 
			
		||||
 | 
			
		||||
                # print("\n".join([src, dst, perms]))
 | 
			
		||||
                src = fsdec(os.path.abspath(fsenc(src)))
 | 
			
		||||
                dst = dst.strip("/")
 | 
			
		||||
 
 | 
			
		||||
@@ -44,14 +44,15 @@ class Cpp(object):
 | 
			
		||||
 | 
			
		||||
    def await_idle(self, ub, timeout):
 | 
			
		||||
        req = ["scanning</td><td>False", "hash-q</td><td>0", "tag-q</td><td>0"]
 | 
			
		||||
        lim = int(timeout * 10)
 | 
			
		||||
        u = ub + "?h"
 | 
			
		||||
        for _ in range(timeout * 10):
 | 
			
		||||
        for n in range(lim):
 | 
			
		||||
            try:
 | 
			
		||||
                time.sleep(0.1)
 | 
			
		||||
                r = requests.get(u, timeout=0.1)
 | 
			
		||||
                for x in req:
 | 
			
		||||
                    if x not in r.text:
 | 
			
		||||
                        print("ST: miss " + x)
 | 
			
		||||
                        print("ST: {}/{} miss {}".format(n, lim, x))
 | 
			
		||||
                        raise Exception()
 | 
			
		||||
                print("ST: idle")
 | 
			
		||||
                return
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user