aboutsummaryrefslogtreecommitdiffhomepage
path: root/tools/skqp/setup_resources
blob: 22f27a85dd33c93fa8acabc00c905b4346844d36 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#! /usr/bin/env python

# Copyright 2018 Google Inc.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.

import os
import shutil
import sys

if __name__ == '__main__':
    skia = os.path.join(os.path.dirname(__file__), os.path.pardir, os.path.pardir)
    dst = os.path.join(skia, 'platform_tools', 'android', 'apps', 'skqp',
                       'src', 'main', 'assets', 'resources')
    if os.path.isdir(dst) and not os.path.islink(dst):
        shutil.rmtree(dst)
    elif os.path.exists(dst):
        os.remove(dst)
    shutil.copytree(os.path.join(skia, 'resources'), dst)