sn

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Jan 12, 2024 License: GPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ProcessConversionAndSaveToFile added in v0.0.7

func ProcessConversionAndSaveToFile(nooks []notesnook.Nook) error

Types

type AppData added in v0.0.7

type AppData struct {
	OrgStandardnotesSn map[string]string `json:"org.standardnotes.sn"`
}

type Content

type Content struct {
	Text             string      `json:"text"`
	Title            string      `json:"title"`
	NoteType         NoteType    `json:"noteType"`
	EditorIdentifier string      `json:"editorIdentifier"`
	References       []Reference `json:"references"` // only tags have references to their notes and to their parents
	AppData          AppData     `json:"appData"`
	PreviewPlain     string      `json:"preview_plain"`
	Spellcheck       bool        `json:"spellcheck"`
}

type ContentType

type ContentType string
const (
	ContentTypeNote ContentType = "Note"
	ContentTypeTag  ContentType = "Tag"
)

type Item

type Item struct {
	ContentType        ContentType `json:"content_type"`
	Content            Content     `json:"content"`
	CreatedAtTimestamp int64       `json:"created_at_timestamp"`
	CreatedAt          string      `json:"created_at"`
	Deleted            bool        `json:"deleted"`
	UpdatedAtTimestamp int64       `json:"updated_at_timestamp"`
	UpdatedAt          string      `json:"updated_at"`
	UUID               uuid.UUID   `json:"uuid"`
}

type NoteType

type NoteType string
const NoteTypePlainText NoteType = "plain-text"

type Reference

type Reference struct {
	UUID          uuid.UUID      `json:"uuid"`
	ContentType   ContentType    `json:"content_type"`
	ReferenceType *ReferenceType `json:"reference_type"`
}

type ReferenceType

type ReferenceType string
const ReferenceTypeTagToParentTag ReferenceType = "TagToParentTag"

type StandardNotes

type StandardNotes struct {
	Version Version `json:"version"`
	Items   []Item  `json:"items"`
}

func ConvertNotebooksToTags

func ConvertNotebooksToTags() StandardNotes

type Version

type Version string
const Version004 Version = "004"

Jump to

Keyboard shortcuts

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