Remove duplicate dependencies (#3961)

* chore: Replace surf with reqwest

Removes a lot of older, duplication versions of some dependencies
(roughtly 90 dependencies removed in total)

* chore: Remove syn 0.11

* chore: Remove unnecessary features from ptree

Removes some more duplicate dependencies

* cargo update

* Ensure we run the fetch and post plugins on the tokio runtime

* Fix clippy warning

* fix: Github requires a user agent on requests

Co-authored-by: Darren Schroeder <343840+fdncred@users.noreply.github.com>
This commit is contained in:
Markus Westerlind
2021-08-28 05:34:11 +02:00
committed by GitHub
parent 7fe05b8296
commit 1c1c58e802
11 changed files with 553 additions and 1733 deletions

View File

@ -6,7 +6,7 @@ use nu_source::{HasSpan, Span, Spanned, SpannedItem};
use super::token_group::TokenBuilder;
#[derive(Debug, Clone, PartialEq, is_enum_variant)]
#[derive(Debug, Clone, PartialEq)]
pub enum TokenContents {
/// A baseline token is an atomic chunk of source code. This means that the
/// token contains the entirety of string literals, as well as the entirety
@ -34,6 +34,12 @@ impl fmt::Display for TokenContents {
}
}
impl TokenContents {
pub fn is_eol(&self) -> bool {
matches!(self, Self::Eol)
}
}
pub type CommandBuilder = TokenBuilder<Spanned<String>>;
pub type CommentsBuilder = TokenBuilder<LiteComment>;
pub type PipelineBuilder = TokenBuilder<LiteCommand>;

View File

@ -1,6 +1,4 @@
#[macro_use]
extern crate derive_is_enum_variant;
#[macro_use]
extern crate derive_new;
mod errors;