Andres Suarez zertosh @facebook New York, NY

browserify/browserify 13093

browser-side require() the node.js way

browserify/watchify 1756

watch mode for browserify builds

prettier/eslint-plugin-prettier 1372

ESLint plugin for Prettier formatting

hughsk/envify 855

:wrench: Selectively replace Node-style environment variables with plain strings.

browserify/detective 371

Find all calls to require() no matter how deeply nested using a proper walk of the AST

zertosh/beautify-with-words 310

Beautifies javascript and replaces variable names with unique "long-ish words"

sindresorhus/gulp-size 222

Display the size of your project

browserify/module-deps 199

walk the dependency graph to generate a stream of json output

browserify/browser-pack 162

pack node-style source files from a json stream into a browser bundle

suda/tool-bar 153

Package providing customisable toolbar for Atom

issue openeddtolnay/trybuild

Turning `path!` into its own crate

I was looking to implement Div for Path and came across:, which led me here. The path! macro ( implemented here is really cool. Any chance you can publish that as its own crate?

created time in 21 days

pull request commentfacebook/react-native

Remove FB copyright notices from iOS template

@TheSavior, the template/ directory is already excluded from the linter. If you want to make sure these files don't get license header by mistake, then just add a pattern lint for "copyright" that covers these files.


comment created time in 2 months

issue openedsoc/dirs-rs

sudo and $HOME

When running with sudo, dirs-rs returns directories for the user calling sudo and not the user that's running under sudo.

On the surface this can seem like expected behavior but it becomes a real problem when a tool is run with sudo, uses dirs::cache_dir, and ends up creating that directory when it doesn't exist.

Unsetting $HOME before using dirs-rs causes dirs-sys-rs's home_dir to use getpwuid_r in the "fallback" logic. This ends up returning the home dir for the user running under sudo. But it's a really ugly workaround. Although sudo has an -H flag to replace $HOME, you don't tend to expect a tool to end up creating a ~/.cache owned by say root when you don't use -H.

I'm not sure if it's a good idea to never trust $HOME, but would it be possible to offer another set of methods that use the "real home dir"?

created time in 2 months

pull request commentrust-lang/git2-rs

Bump versions of git2 and libgit2-sys

Thank you!


comment created time in 3 months

pull request commentrust-lang/git2-rs

Add a missing initialization in `Patch::from_buffers`.

Can a release be made with this fix please?


comment created time in 3 months

Pull request review commentrust-lang/git2-rs

Implement Debug for Patch and related diff structs

 impl<'a> Binding for DiffLine<'a> {     } } +impl<'a> std::fmt::Debug for DiffLine<'a> {+    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {+        let mut ds = f.debug_struct("DiffLine");+        if let Some(old_lineno) = &self.old_lineno() {+            ds.field("old_lineno", old_lineno);+        }+        if let Some(new_lineno) = &self.new_lineno() {+            ds.field("new_lineno", new_lineno);+        }+        ds.field("num_lines", &self.num_lines())+            .field("content_offset", &self.content_offset())+            .field("content", &self.content())

I wonder if it makes more sense to print this field like so:

.field("content", &format_args!("[{} bytes]", self.content().len()))

comment created time in 3 months

PR opened rust-lang/git2-rs

Implement Debug for Patch and related diff structs

These are tricky structs to debug and understand. They can really benefit from being Debug-printable.

+76 -0

0 comment

2 changed files

pr created time in 3 months

create barnchzertosh/git2-rs

branch : patch-debug

created branch time in 3 months

fork zertosh/git2-rs

libgit2 bindings for Rust

fork in 3 months

pull request commentpvinis/react-native

[pull] master from facebook:master

What's the reason for moving the LICENSE word to the next line?

I'm unifying the license headers internally. Our guidelines have had LICENSE on the second line for a long time, plus there are more files with LICENSE on the second line than on the first (across all Facebook projects). So it was hard to justify keeping a variant of this header with LICENSE on the first line.


comment created time in 4 months