;+ ; ; Laboratory for Atmospheric and Space Physics ; University of Colorado, Boulder, Colorado, USA ; ; AUTHOR: ; Lon Riesberg ; ; DATE: July 26. 2007 ; ; PURPOSE: ; Permits establishment of a global production flag that can be obtained ; using the sister routine get_production_flag. This is particularly ; useful for determining whether to update the CIPS observation catalog. ; ; ALGORITHM: ; Set a static variable. ; ; REFERENCES ; None. ; ; NOTES ; Requires that the user be logged in as aimsds. This prevents ; someone from running code in their own sandbox and accidently ; altering databases (e.g. CIPS Observation Catalog) and or sending ; PAN's. ; ; CONSTRAINTS: ; None ; ; INPUT PARAMETERS: ; None ; ; OUTPUT PARAMETERS: ; None. ; ; RETURN VALUE (if applicable): ; Not Applicable ; ; KEYWORD ARGUMENTS: ; flag - needs to be set to 1 to set the production flag. ; set up this way to allow passing a 1 or 0 around ; between bash scripts to indicate that production ; processing is intended ; ; OTHER SERVERS/MODULES USED: ; None ; ; RELATED MODULES / CLASSES: ; get_production_flag.pro ; ; SUPPORTING DATABASE TABLES OR FILES: ; None. ; ; USAGE EXAMPLE: ; set_production_flag, flag=1 ;- pro set_production_flag, flag=flag COMMON PRODUCTION, production_flag production_flag = 0 if keyword_set(flag) eq 1 then begin spawn, 'whoami', user if (strcmp(user, 'aimpro') eq 1) then production_flag = flag endif print, "Set production flag to: ", production_flag end