refactor samples, remove OS dependencies

Issue #35 resolved
Reimar Bauer created an issue

In Windows wie have HOMEPATH while in linux it is HOME

We should check the examples to use sys.platform

Comments (4)

  1. Joern Ungermann

    Sounds good to take this into account. On my Windows7 system HOMEPATH does not give an absolute path...

    There may be something in a python standard module to help us: This from os.path import expanduser home = expanduser("~") is supposed to work on all platforms. From quick testing, it works on my Windows7 machine and ob debian Lenny.

  2. Reimar Bauer reporter

    With the refactoring of mss to use a json config file and also start without that in place we have now a tempdir in place. Other places may also call tempfile.gettempdir()

    wms_cache=config_loader(dataset="wms_cache", default=os.path.join(tempfile.gettempdir(), "mui_wms_cache")))
    

    The default can be overwritten by the entry in the json file.

  3. Reimar Bauer reporter

    This was during many commits solved, most was done by refactoring mss to use a json config file with sane defaults and the other parts with refactoring the server code and configs.

  4. Log in to comment