Skip to content

Conversation

@HassanOHOsman
Copy link

@HassanOHOsman HassanOHOsman commented Nov 24, 2025

Self checklist

  • I have titled my PR with Region | Cohort | FirstName LastName | Sprint | Assignment Title
  • My changes meet the requirements of the task
  • I have tested my changes
  • My changes follow the style guide

This PR provides implementations of shell tools: cat, ls, and wc, using JavaScript with Node.js.

Questions

Is the point of implementing those shell command as a way to appreciate the connivance they provide?
Are there any special cases where implementing shell commands might be needed?

Update: Having just stated Sprint 4, I now know that Shell command tools may not provide a full resolution to our problem. So to me, this is an example of when we could resort to building our own custom tools.

…es when handle wc for a directory with mutiple files
@HassanOHOsman HassanOHOsman added Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. 📅 Sprint 3 Assigned during Sprint 3 of this module labels Nov 24, 2025
Copy link

@MattGoodwin0 MattGoodwin0 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You've got a good understanding of wc, ls and cat commands.

Take a look at the layout of your code files to ensure a consistent format - using a standard format will make it easier to read and review your code.

Could you add some wording around the advantage of having separate package.json files?

let allContent = directoryContent;

if (!options.a) {
allContent = directoryContent.filter(name => !name.startsWith("."));

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What would happen if a directory was not provided - are we able to handle this?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi Matt, apologies for the very delayed response!
Thanks for bringing this to my attention.
I've just added validation to handle such a case.
Please review and let me know.

@MattGoodwin0 MattGoodwin0 added Reviewed Volunteer to add when completing a review with trainee action still to take. and removed Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. labels Dec 21, 2025
change variable keryword assignemnt for  from cosnt to let
@HassanOHOsman HassanOHOsman added Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. and removed Reviewed Volunteer to add when completing a review with trainee action still to take. labels Jan 9, 2026
@HassanOHOsman
Copy link
Author

You've got a good understanding of wc, ls and cat commands.

Take a look at the layout of your code files to ensure a consistent format - using a standard format will make it easier to read and review your code.

Could you add some wording around the advantage of having separate package.json files?

Regarding "Could you add some wording around the advantage of having separate package.json files?", was this a question in a backlog? I could not locate it if that was the case.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. 📅 Sprint 3 Assigned during Sprint 3 of this module

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants