If you're just worried about the one file here's how I'd do it:
import shutil
fileName = 'myfile.ini'
workingFolder = 'D:\\temp\\'
destinationFolders = ['folder1', 'folder2']
if fileName in eg.event.payload[0].lower():
for folder in destinationFolders:
shutil.copy(workingFolder + fileName ...
Notice: This forum has been recovered from an old backup, so some content, links, and dates may be outdated. The forum is currently read-only while we restore sign-in and registration functionality. Details
If you find this forum valuable and would like to help keep it online, donations to help cover hosting and domain costs are greatly appreciated, but never expected. You can support the forum through Buy Me a Coffee or Ko-fi. Thank you for helping preserve the EventGhost community.
If you find this forum valuable and would like to help keep it online, donations to help cover hosting and domain costs are greatly appreciated, but never expected. You can support the forum through Buy Me a Coffee or Ko-fi. Thank you for helping preserve the EventGhost community.
Search found 9 matches
- Wed Sep 03, 2014 4:06 am
- Forum: General Support
- Topic: Directory Watcher - Copy Files
- Replies: 23
- Views: 28769
- Sat Feb 11, 2012 11:35 pm
- Forum: General Support
- Topic: Change 'Playback Devices' in Control Panel (Sound)
- Replies: 11
- Views: 7798
Re: Change 'Playback Devices' in Control Panel (Sound)
Anyone else looking for a solution to this, at least in windows 7, should check out: http://www.daveamenta.com/2011-05/progr ... windows-7/
- Sat Apr 09, 2011 3:13 pm
- Forum: General Support
- Topic: Directory Watcher - Copy Files
- Replies: 23
- Views: 28769
Re: Directory Watcher - Copy Files
I ended up making my own script as I don't want to copy everything to the same folder for various complicated reasons but you should be able to mix and match the best from both scripts. I did some testing but couldn't recreate your issue with video files in a folder not copying over so not sure what ...
- Sat Apr 02, 2011 6:51 pm
- Forum: General Support
- Topic: Directory Watcher - Copy Files
- Replies: 23
- Views: 28769
Re: Directory Watcher - Copy Files
If you still need this photosis, I expanded the logic a bit
import shutil
import os
IgnoreFileTypes = 'txt,nfo'
IgnoreFileNames = ('sample', 'ignore')
FileName = ''.join(eg.event.payload)
isFolder = os.path.isdir(FileName)
DestFolder = 'E:\\Sort\\'
def CopyFileCheck(File):
CopyFile = True
for ...
import shutil
import os
IgnoreFileTypes = 'txt,nfo'
IgnoreFileNames = ('sample', 'ignore')
FileName = ''.join(eg.event.payload)
isFolder = os.path.isdir(FileName)
DestFolder = 'E:\\Sort\\'
def CopyFileCheck(File):
CopyFile = True
for ...
- Sat Apr 02, 2011 2:22 pm
- Forum: General Support
- Topic: Detecting automatic resume from standby vs manual
- Replies: 8
- Views: 7619
Re: Detecting automatic resume from standby vs manual
This should work for you, I had to use powercfg back in the day to figure out a sleep issue. I think powercfg needs admin access to run so you might have to fiddle with it a bit, maybe have EG run under the admin account.
You'll only need to run this once after your computer wakes to record a show ...
You'll only need to run this once after your computer wakes to record a show ...
- Sat Aug 01, 2009 1:38 am
- Forum: Coding Corner
- Topic: computer status plugin, eg.globals and more
- Replies: 5
- Views: 2953
Re: computer status plugin, eg.globals and more
Here's the end result if anyone is interested, it's still rough, I didn't bother turning it into a real plugin with a config window since there's not much interest in it.
Required plugins:
Network Event Receiver
Network Messaging __init__.py
EG Macro: Network Messaging Handler
System ...
Required plugins:
Network Event Receiver
Network Messaging __init__.py
EG Macro: Network Messaging Handler
System ...
- Mon Jul 13, 2009 9:51 pm
- Forum: Coding Corner
- Topic: computer status plugin, eg.globals and more
- Replies: 5
- Views: 2953
Re: computer status plugin, eg.globals and more
I got EG restarting after some work. I was hoping to create a eg.app.Restart() method but EG has issues when a copy of itself is starting while another is exiting. I also tried a batch as well which would work but EG doesn't always exit fast for me and didn't want to stick a long delay in there. In ...
- Sat Jul 11, 2009 12:14 am
- Forum: Coding Corner
- Topic: computer status plugin, eg.globals and more
- Replies: 5
- Views: 2953
Re: computer status plugin, eg.globals and more
Thanks for the wealth of information stottle, python shell is definitely going to be handy.
1. I'm throwing away all globals, that's obviously the wrong way to do it, and now that I know more about Python I can do it the right way.
3. I'm thinking of a way for the plugin to capture/detect events ...
1. I'm throwing away all globals, that's obviously the wrong way to do it, and now that I know more about Python I can do it the right way.
3. I'm thinking of a way for the plugin to capture/detect events ...
- Fri Jul 10, 2009 3:04 am
- Forum: Coding Corner
- Topic: computer status plugin, eg.globals and more
- Replies: 5
- Views: 2953
computer status plugin, eg.globals and more
Hi guys,
I just started getting into EG scripting/Python and have come across a few hurdles I was hoping you guys could help me out with.
First my pet project if anyone is interested. I thought it would be neat to be able to receive status updates from the computers on my network. ie. I WOL a ...
I just started getting into EG scripting/Python and have come across a few hurdles I was hoping you guys could help me out with.
First my pet project if anyone is interested. I thought it would be neat to be able to receive status updates from the computers on my network. ie. I WOL a ...