SageTV Community  

Go Back   SageTV Community > SageTV Products > SageTV Software
Forum Rules FAQs Community Downloads Today's Posts Search

Notices

SageTV Software Discussion related to the SageTV application produced by SageTV. Questions, issues, problems, suggestions, etc. relating to the SageTV software application should be posted here. (Check the descriptions of the other forums; all hardware related questions go in the Hardware Support forum, etc. And, post in the customizations forum instead if any customizations are active.)

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 08-25-2009, 12:56 PM
fabiotv fabiotv is offline
Sage User
 
Join Date: Nov 2008
Posts: 64
Automatically move a file at the end of a rec.

Is there a way to tell Sage to automatically move a file to another folder after a recording ends?

Thanks.
Reply With Quote
  #2  
Old 08-25-2009, 01:03 PM
gplasky's Avatar
gplasky gplasky is offline
SageTVaholic
 
Join Date: Jul 2003
Location: Howell, MI
Posts: 9,203
No. But you can probably do it with Dirmon2 or SJQ.

Gerry
__________________
Big Gerr
_______
Server - WHS 2011: Sage 7.1.9 - 1 x HD Prime and 2 x HDHomeRun - Intel Atom D525 1.6 GHz, Acer Easystore, RAM 4 GB, 4 x 2TB hotswap drives, 1 x 2TB USB ext Clients: 2 x PC Clients, 1 x HD300, 2 x HD-200, 1 x HD-100 DEV Client: Win 7 Ultimate 64 bit - AMD 64 x2 6000+, Gigabyte GA-MA790GP-DS4H MB, RAM 4GB, HD OS:500GB, DATA:1 x 500GB, Pace RGN STB.
Reply With Quote
  #3  
Old 08-25-2009, 01:15 PM
fabiotv fabiotv is offline
Sage User
 
Join Date: Nov 2008
Posts: 64
Do you know which is the easier to get started with, please?

Thanks.
Reply With Quote
  #4  
Old 08-25-2009, 01:27 PM
doc's Avatar
doc doc is offline
Sage Fanatic
 
Join Date: Jun 2006
Location: Leicester, England
Posts: 918
dirmon2 is probably easier for simple stuff, but if you want to move recordings to different folders depending on channel, programme name etc then you'll need SJQ
Reply With Quote
  #5  
Old 08-25-2009, 01:32 PM
fabiotv fabiotv is offline
Sage User
 
Join Date: Nov 2008
Posts: 64
Thanks.
Reply With Quote
  #6  
Old 08-25-2009, 07:39 PM
wayner wayner is offline
SageTVaholic
 
Join Date: Jan 2008
Location: Toronto, ON
Posts: 7,491
I use SJQ to convert kids shows to Divx format and move to a specific folder based on the show - i.e. /Dora/ - SJQ can do this in one command.
__________________
New Server - Sage9 on unRAID 2xHD-PVR, HDHR for OTA
Old Server - Sage7 on Win7Pro-i660CPU with 4.6TB, HD-PVR, HDHR OTA, HVR-1850 OTA
Clients - 2xHD-300, 8xHD-200 Extenders, Client+2xPlaceshifter and a WHS which acts as a backup Sage server
Reply With Quote
  #7  
Old 08-25-2009, 11:22 PM
fabiotv fabiotv is offline
Sage User
 
Join Date: Nov 2008
Posts: 64
Quote:
Originally Posted by wayner View Post
I use SJQ to convert kids shows to Divx format and move to a specific folder based on the show - i.e. /Dora/ - SJQ can do this in one command.
Do you mind helping me with this, please?

I would like to move a file after it has finished recording.

My recording files are named like: 55_6_0721_0755-0.mpg.

I would like to move them like this:

from 55_6_0721_0755-0.mpg to L:\Italia uno\09 07 luglio 21 ore 07.55.mpg where:

- the first two characters define the folder (55=Italia uno)
- than I put the year (09)
- than, after the second "_" there is the month (07=07 luglio) and the day 21
- in the end there is the starting time (0755=ore 07.55)

The folders already exists.

At the beginning I would delete the old files manually but after the script will pass some test I would like to delete the originals automatically.

Thank you for your attention.
Reply With Quote
  #8  
Old 08-26-2009, 01:57 AM
Fuzzy's Avatar
Fuzzy Fuzzy is offline
SageTVaholic
 
Join Date: Sep 2005
Location: Jurupa Valley, CA
Posts: 9,957
Are these recordings being done with SageTV? Those filenames certainly don't look like sage originated files. SJQ might not be that easy to use if these are being generated by something else, as it pretty much relies on the recording metadata from the Sage database.
__________________
Buy Fuzzy a beer! (Fuzzy likes beer)

unRAID Server: i7-6700, 32GB RAM, Dual 128GB SSD cache and 13TB pool, with SageTVv9, openDCT, Logitech Media Server and Plex Media Server each in Dockers.
Sources: HRHR Prime with Charter CableCard. HDHR-US for OTA.
Primary Client: HD-300 through XBoxOne in Living Room, Samsung HLT-6189S
Other Clients: Mi Box in Master Bedroom, HD-200 in kids room
Reply With Quote
  #9  
Old 08-26-2009, 02:03 AM
fabiotv fabiotv is offline
Sage User
 
Join Date: Nov 2008
Posts: 64
Yes, they are. Sage 6.5.9

The first two characters are the channel number given by the video device setup. The number after the first "_" is the number I assigned them. The rest are date and time etc.

Thanks.
Reply With Quote
  #10  
Old 08-26-2009, 07:28 AM
wayner wayner is offline
SageTVaholic
 
Join Date: Jan 2008
Location: Toronto, ON
Posts: 7,491
Here is my SJQ code. When you talk about a two letter code like 55 are there lots of these different codes? I am not sure how to loop through these to automate the copying to the different folders - to do that you would have to parse the two characters out of the name. If there aren't too many then you could just use the brute force method. So in other words you would exchange wherevere you find "Dora" below with "55" and then create another if statement for "56" and all others. Note that I am also reencoding the shows which you may or may not want to do. I don't know how to do this without reencoding the shows - perhaps you can set the output file type to MPEG-2 and it won't reencode or it will reencode to the same format. But there is no real downside to reencoding to MPEG-4 as it will save you disk space and you can select a high enough quality setting that it won't degrade the quality of the file.

Here is what is happening in the code below - I am looking for TV files that are in MPEG format that are not actively recording and have "Dora" in the filename. I am then running separate checks to see if the metadata includes s subtitle i.e. "Dora and Boots save the Tico" and if there is then I rename the file with the subtitle. Otherwise I keep the number Sage assigns as the filename. The reason that I have to do this is that some shows don't have subtitles and this would cause problems.

Note that with this methodology the files are moved and the Sage database knows where they are. The downside to this is that they don't appear to show up in your Videos Library but they do show up in TV.

Code:
// Process Dora shows with a valid subtitle
if [IsTV == "true" && FileExists == "%d%\\%p%.mpg" && FileExists != "%d%\\%p%.avi" && IsActivelyRecording == "false" && Filename =*"Dora" && Episode != ""]
{
   :TRANSCODEOPTS "MPEG4-Good Quality Deinterlaced AVI" "false" "\\\\standrews\\videos\\Isabella's Shows\\Dora\\%s%.avi"
    _TRANSCODE
}

// Process Dora shows without a valid subtitle
if [IsTV == "true" && FileExists == "%d%\\%p%.mpg" && FileExists != "%d%\\%p%.avi" && IsActivelyRecording == "false" && Filename =*"Dora" && Episode == ""]
{
   :TRANSCODEOPTS "MPEG4-Good Quality Deinterlaced AVI" "false" "\\\\standrews\\videos\\Isabella's Shows\\Dora\\%f%.avi"
    _TRANSCODE
}
__________________
New Server - Sage9 on unRAID 2xHD-PVR, HDHR for OTA
Old Server - Sage7 on Win7Pro-i660CPU with 4.6TB, HD-PVR, HDHR OTA, HVR-1850 OTA
Clients - 2xHD-300, 8xHD-200 Extenders, Client+2xPlaceshifter and a WHS which acts as a backup Sage server
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
AAAARRRRRGGGG!! File move frustration nick_l SageTV Beta Test Software 0 05-18-2009 07:39 AM
How long *should* it take to move a 6Gb file? matt91 Hardware Support 17 12-04-2007 12:33 PM
End of File bug Grey_Goose SageTV Software 19 06-26-2004 09:45 PM
end of file bug Maladin SageTV Beta Test Software 14 04-15-2004 02:09 AM
Is it possible to move a file to a specific directory ldavis SageTV Software 0 09-20-2003 08:45 AM


All times are GMT -6. The time now is 10:57 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2023, vBulletin Solutions Inc.
Copyright 2003-2005 SageTV, LLC. All rights reserved.