View Single Post
Old 09-24-2016, 12:14 PM   #5
Divingduck
Wizard
Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.
 
Posts: 1,166
Karma: 1410083
Join Date: Nov 2010
Location: Germany
Device: Sony PRS-650
Guess he wasn't able to set the variable correct.

@gsevrain

as usual, there a several way's to do what Kovid mentioned. One method is pointed a the end of the variables listing (see above link from Kovid) called
See How to set environment variables in windows or How to set environment variables in OS X and click on the first link.

An other way for testing is to use a batch file what will set your environment variable. I use two batches, one for set up and one for deleting the variable after I finish my tests. Place it into your desktop so that you can easy use it. Here an example:

First batch (e.g. set_env.bat) for set up the variable
Spoiler:
Code:
echo off
REM
REM Set environment variable for CALIBRE_CONFIG_DIRECTORY
REM
cls

  echo ********************************************************
  echo
  echo all environment variables starting with c before change:
  echo ********************************************************
  
  set c
  setx CALIBRE_CONFIG_DIRECTORY c:\Users\YOUR_USER_NAME\Documents\Calibre\Calibre-Development\Developmentconfig\

  pause
echo on


and a batch file (e.g. del_env.bat) for deleting the variable
Spoiler:
Code:
echo off
REM
REM Delete environment variable for CALIBRE_CONFIG_DIRECTORY
REM
cls

  echo ********************************************************
  echo 
  echo All environment variables starting with c before change:
  echo ********************************************************
  
  set c
  
  setx CALIBRE_CONFIG_DIRECTORY ""
    
  pause
echo on


First create a new directory for your test and then change the line setx c:\Users\YOUR_USER_NAME\Documents\Calibre\Calibre-Development\Developmentconfig\ in the first batch file to your needs. Keep in mind, if your directory name includes spaces like my directory, you need to use apostrophes like "my directory"
Create the batch files with an editor like wordpad, notepad or any other editor (but not MS Word) and save the file with extension "bat" (like set_env.bat). The command pause waits for any keyboard input. If you don't need it, add a REM at the beginning of the line like REM pause or simply delete the line.

Usage: run first the "set_env.bat" then you can start calibre as usual and do your tests. After you had finished your test, close calibre (ctrl+q) and run the second batch file "del_env.bat". After this calibre will run with the default directory again.

Good luck!
Divingduck is offline   Reply With Quote