Skip to content

WIP - Add man pages#236

Merged
ampinsk merged 40 commits intogh-pagesfrom
docs-test
Feb 4, 2020
Merged

WIP - Add man pages#236
ampinsk merged 40 commits intogh-pagesfrom
docs-test

Conversation

@ampinsk
Copy link
Copy Markdown

@ampinsk ampinsk commented Jan 17, 2020

Opening this for visibility! This is targeting @gladwearefriends's landing page work in #235, so that should be merged first

To Dos

Man page generation

  • Load all man pages under /manual/ directory (@mislav I may need some help from you here!)
  • Regenerate man pages with more recent changes that have been made (@mislav will need your help here too!)

Visual bugs and details

  • Add release notes link to repo, and remove docs link in the meantime
  • Responsive (also needing some assistance here)
    • Mobile sidenav
    • Code blocks cutting off weird
  • Sidenav not taking up full height
  • Anchor links link to a confusing spot on examples page
  • gh in sidenav should be Overview
  • Make sure ordering is consistent

Example content

  • Create example of use standalone pages
  • Add examples of use the command pages
    • Right now, I'm showing both pr and issue examples on the command pages. It's a little confusing and should just be issue or pr examples on their respective pages.
  • Add content on forks with gh pr create
  • Pass for better example content titles

Future nice to haves

  • Automate example generation
  • Syntax highlighting on examples

Here's what it looks like right now:

Screen Shot 2020-01-16 at 5 21 21 PM

cc @trosage since you're wrapping up Catherine's work!

Closes #77

@ampinsk ampinsk linked an issue Jan 17, 2020 that may be closed by this pull request
3 tasks
@mislav
Copy link
Copy Markdown
Contributor

mislav commented Jan 22, 2020

@ampinsk This looks great!

I'm going to take a note of moving man pages to under manual/. It shouldn't be much of a problem.

In the meantime, I've wanted to find a solution to generate sidebar links in docs-nav.html dynamically so the sidebar doesn't fall out of date whenever we add or rename a command. I've added the commit with my idea— it's not pretty, but I think it does the job, with an added bonus of styling the currently active link with bold. Feel free to change the active link styling!

@ampinsk
Copy link
Copy Markdown
Author

ampinsk commented Jan 30, 2020

Updated the body with some more detailed todos! Getting to a place where I need some help with some of these remaining tasks.

Amanda Pinsker added 2 commits January 30, 2020 14:21
Decided to not do white on black because it's way more jarring to scan on the page
Amanda Pinsker and others added 11 commits January 30, 2020 14:31
These rules would make us unable to display any unordered list or `<h6>`
to manual pages in the future, even if they're unrelated to the "SEE
ALSO" section.

We now strip "SEE ALSO" and the footer when we regenerate man pages into
the `gh-pages` branch.
As long as we have a sticky header, we can't safely link to an anchor in
the middle of the page (such as in Examples) because the resulting
scroll position will have the target heading be obscured by the sticky
header element.

In github.com we solve this using JavaScript, but the solution is not
easily portable and doesn't always work really well with back-forward
navigation. There are content or CSS workarounds offered on the
internet, but they usually require content changes or sacrificing
accessibility.

The easiest way to allow linking to an anchor on the page is to avoid
having a sticky header.
@mislav
Copy link
Copy Markdown
Contributor

mislav commented Jan 31, 2020

I've nested man pages under /manual/; the top-level page being /manual/gh now. Let me know how it looks!

How to update man pages after future releases of gh:

  1. Ensure Update make site-docs to reflect latest setup #285 is first merged;
  2. git checkout master;
  3. make site-docs.

The last step can potentially be automated via release automation, so we don't have to always remember to do it manually, but to pull that switch I'd first wait for the site to stop being in flux.

  • Anchor links link to a confusing spot on examples page

I've noticed that too, right now I've disabled the sticky header to fix that. My rationale is in the commit message

  • Syntax highlighting on examples

This one is tricky 😕 Jekyll has built-in support for syntax highlighting code from different programming languages, but terminal prompt and command output is not any specific language, so we can't really use the Jekyll feature. I think we are forced to resort to manual syntax highlighting using <span>s for now.

Copy link
Copy Markdown

@sophshep sophshep left a comment

Choose a reason for hiding this comment

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

  • How can the landing page and man pages be more connected? Right now they feel very separate since the landing page has the full github nav. Personally, I don't think it needs this and it can be the collapsed version, like on https://education.github.com/ There may be some other ways to bring the marketing styles to the manual too.
  • The content strategy of these feels unnecessarily separated out to me. Do you need the "examples in use" in the sidebar if those examples are in context with the commands?
  • The hierarchy in the sidebar could be more clear. Maybe like:
Installation
Commands
  gh
      help
  issue
      create
      list
      status
      view
  pr
      checkout
      create
      list
      status
  • When there's room, it would be nice for the left sidebar to stay fixed
  • Synopsis description is repeated twice on the top of pages

@ampinsk
Copy link
Copy Markdown
Author

ampinsk commented Feb 4, 2020

Hey @sophshep thank you for the feedback, I'm going to address this in a following PR! Wanted to merge this so the current man pages don't look totally borked.

@ampinsk ampinsk changed the base branch from add-landing-page-v2 to gh-pages February 4, 2020 18:56
@ampinsk ampinsk merged commit 35b1612 into gh-pages Feb 4, 2020
@ampinsk
Copy link
Copy Markdown
Author

ampinsk commented Feb 4, 2020

How can the landing page and man pages be more connected? Right now they feel very separate since the landing page has the full github nav. Personally, I don't think it needs this and it can be the collapsed version, like on https://education.github.com/ There may be some other ways to bring the marketing styles to the manual too.

Also this was already fixed! ✨

@ampinsk ampinsk mentioned this pull request Feb 5, 2020
5 tasks
@ampinsk ampinsk deleted the docs-test branch February 5, 2020 23:50
Stonre pushed a commit to Stonre/strands-fork that referenced this pull request Jul 21, 2025
* Add CohereModel

* Format

* Update pyproject.toml

* Update src/strands/models/cohere.py

* Revert cusom cli, keep only compat layer

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Docs/man-page

5 participants