mirror of
https://github.com/google/pebble.git
synced 2025-07-19 08:05:58 +00:00
Import of the watch repository from Pebble
This commit is contained in:
commit
3b92768480
10334 changed files with 2564465 additions and 0 deletions
22
sdk/defaults/lib/lib.c
Normal file
22
sdk/defaults/lib/lib.c
Normal file
|
@ -0,0 +1,22 @@
|
|||
/*
|
||||
* Copyright 2024 Google LLC
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <pebble.h>
|
||||
#include "${project_name}.h"
|
||||
|
||||
bool ${project_name_c}_find_truth(void) {
|
||||
return true;
|
||||
}
|
19
sdk/defaults/lib/lib.h
Normal file
19
sdk/defaults/lib/lib.h
Normal file
|
@ -0,0 +1,19 @@
|
|||
/*
|
||||
* Copyright 2024 Google LLC
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
bool ${project_name_c}_find_truth(void);
|
21
sdk/defaults/lib/lib.js
Normal file
21
sdk/defaults/lib/lib.js
Normal file
|
@ -0,0 +1,21 @@
|
|||
/**
|
||||
* Copyright 2024 Google LLC
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
var run_me = function(e) {
|
||||
console.log("Look at me, I'm running!");
|
||||
};
|
||||
|
||||
module.exports = run_me;
|
21
sdk/defaults/lib/package.json
Normal file
21
sdk/defaults/lib/package.json
Normal file
|
@ -0,0 +1,21 @@
|
|||
{
|
||||
"name": "${project_name}",
|
||||
"author": "MakeAwesomeHappen",
|
||||
"version": "1.0.0",
|
||||
"files": ["dist.zip"],
|
||||
"keywords": ["pebble-package"],
|
||||
"dependencies": {},
|
||||
"pebble": {
|
||||
"projectType": "package",
|
||||
"sdkVersion": "${sdk_version}",
|
||||
"targetPlatforms": [
|
||||
"aplite",
|
||||
"basalt",
|
||||
"chalk",
|
||||
"diorite"
|
||||
],
|
||||
"resources": {
|
||||
"media": []
|
||||
}
|
||||
}
|
||||
}
|
48
sdk/defaults/lib/wscript
Normal file
48
sdk/defaults/lib/wscript
Normal file
|
@ -0,0 +1,48 @@
|
|||
#
|
||||
# This file is the default set of rules to compile a Pebble project.
|
||||
#
|
||||
# Feel free to customize this to your needs.
|
||||
#
|
||||
import os
|
||||
import shutil
|
||||
import waflib
|
||||
|
||||
top = '.'
|
||||
out = 'build'
|
||||
|
||||
|
||||
def distclean(ctx):
|
||||
if os.path.exists('dist.zip'):
|
||||
os.remove('dist.zip')
|
||||
if os.path.exists('dist'):
|
||||
shutil.rmtree('dist')
|
||||
waflib.Scripting.distclean(ctx)
|
||||
|
||||
|
||||
def options(ctx):
|
||||
ctx.load('pebble_sdk_lib')
|
||||
|
||||
|
||||
def configure(ctx):
|
||||
ctx.load('pebble_sdk_lib')
|
||||
|
||||
|
||||
def build(ctx):
|
||||
ctx.load('pebble_sdk_lib')
|
||||
|
||||
cached_env = ctx.env
|
||||
for platform in ctx.env.TARGET_PLATFORMS:
|
||||
ctx.env = ctx.all_envs[platform]
|
||||
ctx.set_group(ctx.env.PLATFORM_NAME)
|
||||
lib_name = '{}/{}'.format(ctx.env.BUILD_DIR, ctx.env.PROJECT_INFO['name'])
|
||||
ctx.pbl_build(source=ctx.path.ant_glob('src/c/**/*.c'), target=lib_name, bin_type='lib')
|
||||
ctx.env = cached_env
|
||||
|
||||
ctx.set_group('bundle')
|
||||
ctx.pbl_bundle(includes=ctx.path.ant_glob('include/**/*.h'),
|
||||
js=ctx.path.ant_glob(['src/js/**/*.js', 'src/js/**/*.json']),
|
||||
bin_type='lib')
|
||||
|
||||
if ctx.cmd == 'clean':
|
||||
for n in ctx.path.ant_glob(['dist/**/*', 'dist.zip'], quiet=True):
|
||||
n.delete()
|
Loading…
Add table
Add a link
Reference in a new issue