github.com/cockroachdb/tools@v0.0.0-20230222021103-a6d27438930d/cmd/present/doc.go (about)

     1  // Copyright 2011 The Go Authors. All rights reserved.
     2  // Use of this source code is governed by a BSD-style
     3  // license that can be found in the LICENSE file.
     4  
     5  /*
     6  Present displays slide presentations and articles. It runs a web server that
     7  presents slide and article files from the current directory.
     8  
     9  It may be run as a stand-alone command or an App Engine app.
    10  
    11  The setup of the Go version of NaCl is documented at:
    12  https://golang.org/wiki/NativeClient
    13  
    14  To use with App Engine, copy the files in the tools/cmd/present directory to the
    15  root of your application and create an app.yaml file similar to this:
    16  
    17  	runtime: go111
    18  
    19  	handlers:
    20  	- url: /favicon.ico
    21  	  static_files: static/favicon.ico
    22  	  upload: static/favicon.ico
    23  	- url: /static
    24  	  static_dir: static
    25  	- url: /.*
    26  	  script: auto
    27  
    28  	# nobuild_files is a regexp that identifies which files to not build.  It
    29  	# is useful for embedding static assets like code snippets and preventing
    30  	# them from producing build errors for your project.
    31  	nobuild_files: [path regexp for talk materials]
    32  
    33  When running on App Engine, content will be served from the ./content/
    34  subdirectory.
    35  
    36  Present then can be tested in a local App Engine environment with
    37  
    38  	GAE_ENV=standard go run .
    39  
    40  And deployed using
    41  
    42  	gcloud app deploy
    43  
    44  Input files are named foo.extension, where "extension" defines the format of
    45  the generated output. The supported formats are:
    46  
    47  	.slide        // HTML5 slide presentation
    48  	.article      // article format, such as a blog post
    49  
    50  The present file format is documented by the present package:
    51  https://pkg.go.dev/golang.org/x/tools/present
    52  */
    53  package main