Reputation: 993
I have to files python1 and python2.
Python2.py has code something like this:
import sys
variable1=value1
variable2=value2
#and some python code from here on
The python1 script should take the input value for variable1 and variable2 and change the corresponding value in python2.py without tampering the other code.
And example 2: If any user gives the variable1 value as android. The value of variable1 in python2 should be changed to android
Thanks
Note: python2 is not a configuration file, has many other modules
Upvotes: 1
Views: 1647
Reputation: 142216
You can just import python2
in python1
, then use python2.variable1=...
Upvotes: 3