Did I find the right examples for you? yes no

All Samples(7)  |  Call(4)  |  Derive(0)  |  Import(3)
Returns True if first_path's mtime is higher than second_path's mtime.

        def modified_after(first_path, second_path):
    """Returns True if first_path's mtime is higher than second_path's mtime."""
    try:
        first_mtime = os.stat(first_path).st_mtime
    except EnvironmentError:
        return False
    try:
        second_mtime = os.stat(second_path).st_mtime
    except EnvironmentError:
        return True
    return first_mtime > second_mtime
        


src/d/u/dupeguru-HEAD/hscommon/loc.py   dupeguru(Download)
 
from . import pygettext
from .util import modified_after, dedupe, ensure_folder, ensure_file
from .build import print_and_do, ensure_empty_folder, copy
 
def po2strings(pofile, en_strings, dest):
    # Takes en_strings and replace all righthand parts of "foo" = "bar"; entries with translations
    # in pofile, then puts the result in dest.
    po = polib.pofile(pofile)
    if not modified_after(pofile, dest):

src/m/o/moneyguru-HEAD/hscommon/loc.py   moneyguru(Download)
 
from . import pygettext
from .util import modified_after, dedupe, ensure_folder, ensure_file
from .build import print_and_do, ensure_empty_folder, copy
 
def po2strings(pofile, en_strings, dest):
    # Takes en_strings and replace all righthand parts of "foo" = "bar"; entries with translations
    # in pofile, then puts the result in dest.
    po = polib.pofile(pofile)
    if not modified_after(pofile, dest):

src/x/i/xibless-0.5.1/xibless/gen.py   xibless(Download)
from .slider import Slider
from .layout import HLayout, VLayout, VHLayout
from .util import modified_after
 
try:
def copy_support_unit(destfolder):
    DATA_PATH = op.join(op.dirname(__file__), 'data')
    if not op.exists(destfolder):
        os.makedirs(destfolder)
    if modified_after(op.join(DATA_PATH, 'XiblessSupport.h'), op.join(destfolder, 'XiblessSupport.h')):
        shutil.copy(op.join(DATA_PATH, 'XiblessSupport.h'), destfolder)
    if modified_after(op.join(DATA_PATH, 'XiblessSupport.m'), op.join(destfolder, 'XiblessSupport.m')):