Sort derive macros
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
use clap::{Parser, Subcommand};
|
use clap::{Parser, Subcommand};
|
||||||
|
|
||||||
#[derive(Parser, Debug)]
|
#[derive(Debug, Parser)]
|
||||||
#[command(version, about, long_about = None)]
|
#[command(version, about, long_about = None)]
|
||||||
pub struct Args {
|
pub struct Args {
|
||||||
#[arg(short = 'o', long = "owner")]
|
#[arg(short = 'o', long = "owner")]
|
||||||
@@ -12,7 +12,7 @@ pub struct Args {
|
|||||||
pub command: Commands,
|
pub command: Commands,
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Subcommand, Debug)]
|
#[derive(Debug, Subcommand)]
|
||||||
pub enum Commands {
|
pub enum Commands {
|
||||||
ListReleases,
|
ListReleases,
|
||||||
CreateRelease {
|
CreateRelease {
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ use serde::{Deserialize, Serialize};
|
|||||||
pub mod cli;
|
pub mod cli;
|
||||||
|
|
||||||
/// A struct matching a Gitea "Release" entry
|
/// A struct matching a Gitea "Release" entry
|
||||||
#[derive(Deserialize, Debug, Serialize)]
|
#[derive(Debug, Deserialize, Serialize)]
|
||||||
pub struct ReleaseInfo {
|
pub struct ReleaseInfo {
|
||||||
id: usize,
|
id: usize,
|
||||||
tag_name: String,
|
tag_name: String,
|
||||||
@@ -22,7 +22,7 @@ pub struct ReleaseInfo {
|
|||||||
author: Author,
|
author: Author,
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Deserialize, Debug, Serialize)]
|
#[derive(Debug, Deserialize, Serialize)]
|
||||||
pub struct Author {
|
pub struct Author {
|
||||||
id: usize,
|
id: usize,
|
||||||
login: String,
|
login: String,
|
||||||
@@ -32,7 +32,7 @@ pub struct Author {
|
|||||||
email: String,
|
email: String,
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Serialize, Debug)]
|
#[derive(Debug, Serialize)]
|
||||||
pub struct CreateReleaseOption {
|
pub struct CreateReleaseOption {
|
||||||
pub body: String,
|
pub body: String,
|
||||||
pub draft: bool,
|
pub draft: bool,
|
||||||
|
|||||||
Reference in New Issue
Block a user