blob: eabe04a18af8375be7b9c65577f00015ce3d549a [file] [log] [blame]
Mark Erickson932c4702015-08-29 10:46:51 -05001#!/bin/sh
2
3# Licensed to the Apache Software Foundation (ASF) under one
4# or more contributor license agreements. See the NOTICE file
5# distributed with this work for additional information
6# regarding copyright ownership. The ASF licenses this file
7# to you under the Apache License, Version 2.0 (the
8# 'License'); you may not use this file except in compliance
9# with the License. You may obtain a copy of the License at
10#
11# http://www.apache.org/licenses/LICENSE-2.0
12#
13# Unless required by applicable law or agreed to in writing,
14# software distributed under the License is distributed on an
15# 'AS IS' BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16# KIND, either express or implied. See the License for the
17# specific language governing permissions and limitations
18# under the License.
19
20set -e;
21rm -r gen-dart || true;
22
23thrift --gen dart ../shared.thrift;
24cd gen-dart/shared;
25pub get;
26cd ../..;
27
28thrift --gen dart ../tutorial.thrift;
29cd gen-dart/tutorial;
30pub get;
31cd ../..;
32
33cd client;
34pub get;
35cd ..;
36
37cd console_client;
38pub get;
39cd ..;
40
41cd server;
42pub get;
43cd ..;
44
45dartfmt -w gen-dart;
46
47echo "\nEnjoy the Dart tutorial!";
48echo "\nTo run the server:";
49echo "> dart server/bin/main.dart";
50echo "\nTo run the client:";
51echo "# Serve the app from the client directory and view in a browser";
52echo "> cd client;";
53echo "> pub serve;";
54echo "\nTo run the console client:";
55echo "> dart console_client/bin/main.dart";
56echo "";