gofff

package module
v0.0.0-...-f2266cd Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 11, 2022 License: AGPL-3.0 Imports: 4 Imported by: 0

README

gofff

Go implementation for the Friendly Forge Format

License

This project is licensed under the AGPLv3+ License.

Documentation

Overview

This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.

You should have received a copy of the GNU Affero General Public License along with this program. If not, see <http://www.gnu.org/licenses/>.

This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.

You should have received a copy of the GNU Affero General Public License along with this program. If not, see <http://www.gnu.org/licenses/>.

This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.

You should have received a copy of the GNU Affero General Public License along with this program. If not, see <http://www.gnu.org/licenses/>.

This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.

You should have received a copy of the GNU Affero General Public License along with this program. If not, see <http://www.gnu.org/licenses/>.

This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.

You should have received a copy of the GNU Affero General Public License along with this program. If not, see <http://www.gnu.org/licenses/>.

Index

Constants

This section is empty.

Variables

View Source
var AllFeatures = Features{
	Wiki:          true,
	Issues:        true,
	Milestones:    true,
	Labels:        true,
	Releases:      true,
	Comments:      true,
	PullRequests:  true,
	ReleaseAssets: true,
}

Functions

This section is empty.

Types

type Configuration

type Configuration struct {
	Verbose                bool
	Directory              string
	NewMigrationHTTPClient NewMigrationHTTPClientFun
}

func (Configuration) GetDirectory

func (c Configuration) GetDirectory() string

func (*Configuration) GetNewMigrationHTTPClient

func (c *Configuration) GetNewMigrationHTTPClient() NewMigrationHTTPClientFun

func (Configuration) GetVerbose

func (c Configuration) GetVerbose() bool

func (*Configuration) SetNewMigrationHTTPClient

func (c *Configuration) SetNewMigrationHTTPClient(fun NewMigrationHTTPClientFun)

type Features

type Features struct {
	Wiki          bool
	Issues        bool
	Milestones    bool
	Labels        bool
	Releases      bool
	Comments      bool
	PullRequests  bool
	ReleaseAssets bool
}

type ForgeInterface

type ForgeInterface interface {
	SetContext(context.Context)

	GetDirectory() string
	GetProject() *format.Project
	GetRepositories() []*format.Repository
	GetTopics() []*format.Topic
	GetMilestones() []*format.Milestone
	GetReleases() []*format.Release
	GetLabels() []*format.Label
	GetIssues() []*format.Issue
	GetComments(commentable format.Commentable) []*format.Comment
	GetAllComments() []*format.Comment
	SupportGetRepoComments() bool
	GetPullRequests() []*format.PullRequest
	GetReviews(reviewable format.Reviewable) []*format.Review

	CreateProject(projects *format.Project)
	CreateRepositories(repositories ...*format.Repository)
	DeleteProject() *format.Project
	CreateTopics(topic ...*format.Topic)
	CreateMilestones(milestones ...*format.Milestone)
	CreateReleases(releases ...*format.Release)
	CreateLabels(labels ...*format.Label)
	CreateIssues(issues ...*format.Issue)
	CreatePullRequests(prs ...*format.PullRequest)
	CreateComments(commentable format.Commentable, comments ...*format.Comment)
	CreateReviews(reviewable format.Reviewable, reviews ...*format.Review)
	Rollback()

	Finish()
}

type Logger

type Logger struct {
	Message  func(string, ...interface{})
	Trace    func(string, ...interface{})
	Debug    func(string, ...interface{})
	Info     func(string, ...interface{})
	Warn     func(string, ...interface{})
	Error    func(string, ...interface{})
	Critical func(string, ...interface{})
	Fatal    func(string, ...interface{})
}

func NewLogger

func NewLogger() Logger

func (*Logger) SetDefaults

func (o *Logger) SetDefaults()

type NewMigrationHTTPClientFun

type NewMigrationHTTPClientFun func() *http.Client

type Options

type Options struct {
	Logger
	Features
	Configuration
}

func (*Options) GetConfiguration

func (o *Options) GetConfiguration() *Configuration

func (*Options) GetLogger

func (o *Options) GetLogger() *Logger

func (*Options) SetDefaults

func (o *Options) SetDefaults()

type OptionsInterface

type OptionsInterface interface {
	SetDefaults()
	GetLogger() *Logger
	GetConfiguration() *Configuration
}

Directories

Path Synopsis
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
abstract
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
file
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
gitea
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
null
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
uri

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL