How to Call a module in appium?

Hi ,
I have a login script. I also have scripts to test some other functionality , once user successfully login.
I do not want to create login function in every script , so i want to call the login script in my other scripts.
Is there any sample script for this to give a try ?