Changeset 6de5e10 in sasview for docs


Ignore:
Timestamp:
Mar 22, 2016 7:55:49 AM (9 years ago)
Author:
butler
Branches:
master, ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc, costrafo411, magnetic_scatt, release-4.1.1, release-4.1.2, release-4.2.2, release_4.0.1, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
Children:
53aa66d
Parents:
a8787f9
Message:

Fixes a couple of instances of not creating source directories — may be
more. Need a thorough checking of code but now builds for me.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • docs/sphinx-docs/build_sphinx.py

    r5420ef6 r6de5e10  
    150150    if os.path.exists(SASMODELS_SOURCE_IMG): 
    151151        print "Found img  folder SASMODELS_SOURCE_IMG    at ", SASMODELS_SOURCE_IMG 
    152         if os.path.exists(SASMODELS_DEST_IMG): 
    153             print "Found img  folder SASMODELS_DEST_IMG      at ", SASMODELS_DEST_IMG 
    154             print "Copying sasmodels model image files..." 
    155             for files in os.listdir(SASMODELS_SOURCE_IMG): 
    156                 fromhere=os.path.join(SASMODELS_SOURCE_IMG,files) 
    157                 tohere=os.path.join(SASMODELS_DEST_IMG,files) 
    158                 shutil.copy(fromhere,tohere) 
     152        if not os.path.exists(SASMODELS_DEST_IMG): 
     153            print "Missing docs folder SASMODELS_DEST_IMG at ", SASMODELS_DEST_IMG 
     154            os.makedirs(SASMODELS_DEST_IMG) 
     155            print "created SASMODELS_DEST_BUILDIMG at ", SASMODELS_DEST_BUILDIMG 
     156        else: print "Found img  folder SASMODELS_DEST_IMG      at ", SASMODELS_DEST_IMG 
     157        print "Copying sasmodels model image files..." 
     158        for files in os.listdir(SASMODELS_SOURCE_IMG): 
     159            fromhere=os.path.join(SASMODELS_SOURCE_IMG,files) 
     160            tohere=os.path.join(SASMODELS_DEST_IMG,files) 
     161            shutil.copy(fromhere,tohere) 
     162    else: print "cannot find SASMODELS_SOURCE_IMG", SASMODELS_SOURCE_IMG 
    159163 
    160164    if os.path.exists(SASMODELS_SOURCE_AUTOIMG): 
    161165        print "Found img  folder SASMODELS_SOURCE_AUTOIMG    at ", SASMODELS_SOURCE_AUTOIMG 
    162         if os.path.exists(SASMODELS_DEST_IMG): 
    163             print "Copying sasmodels model auto-generated image files..." 
    164             for files in os.listdir(SASMODELS_SOURCE_AUTOIMG): 
    165                 fromhere=os.path.join(SASMODELS_SOURCE_AUTOIMG,files) 
    166                 tohere=os.path.join(SASMODELS_DEST_IMG,files) 
    167                 shutil.copy(fromhere,tohere) 
     166        if not os.path.exists(SASMODELS_DEST_IMG): 
     167            print "Missing docs folder SASMODELS_DEST_IMG at ", ASMODELS_DEST_IMG 
     168            os.makedirs(SASMODELS_DEST_BUILDIMG) 
     169            print "created SASMODELS_DEST_BUILDIMG at ", SASMODELS_DEST_BUILDIMG 
     170        print "Copying sasmodels model auto-generated image files..." 
     171        for files in os.listdir(SASMODELS_SOURCE_AUTOIMG): 
     172            fromhere=os.path.join(SASMODELS_SOURCE_AUTOIMG,files) 
     173            tohere=os.path.join(SASMODELS_DEST_IMG,files) 
     174            shutil.copy(fromhere,tohere) 
     175        else: print "no source directorty",SASMODELS_SOURCE_AUTOIMG ,"was found" 
    168176     
    169177    # And the rst prolog with the unit substitutions 
Note: See TracChangeset for help on using the changeset viewer.