This repository has been archived on 2023-02-07. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
flamenco-manager/setupmode.go
Sybren A. Stüvel c911cf2371 Removed LICENSE BLOCK lines + moved license block to top of file
The LICENSE BLOCK lines were there because Blender does that too, but they
are being/have been removed from the Blender sources.

Apparently when there is a newline between the comment and the `package`
keyword, it's no longer interpreted as package documentation (which is why
I had the comment below the `package` keyword in the first place).
2019-03-21 14:06:10 +01:00

45 lines
1.7 KiB
Go

/* (c) 2019, Blender Foundation - Sybren A. Stüvel
*
* Permission is hereby granted, free of charge, to any person obtaining
* a copy of this software and associated documentation files (the
* "Software"), to deal in the Software without restriction, including
* without limitation the rights to use, copy, modify, merge, publish,
* distribute, sublicense, and/or sell copies of the Software, and to
* permit persons to whom the Software is furnished to do so, subject to
* the following conditions:
*
* The above copyright notice and this permission notice shall be
* included in all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package main
import (
"github.com/armadillica/flamenco-manager/websetup"
"github.com/gorilla/mux"
)
func setupMode() (*websetup.Routes, *mux.Router, error) {
// Always do verbose logging while running setup mode. It wouldn't make sense to log normal
// informative things (like the URLs available to access the server) at warning level just to
// ensure visibility.
oldQuiet := cliArgs.quiet
defer func() { cliArgs.quiet = oldQuiet }()
cliArgs.quiet = false
configLogging()
router := mux.NewRouter().StrictSlash(true)
web, err := websetup.EnterSetupMode(&config, applicationVersion, router)
return web, router, err
}