Sample Header Ad - 728x90

Any text utility or hack to numbering poems lines omitting certain numbers?

0 votes
2 answers
301 views
My goal is try to see if there are common text utilities in linux that can be used to number lines of poems like this:
OF Mans First Disobedience, and the Fruit
Of that Forbidden Tree, whose mortal tast
Brought Death into the World, and all our woe,
With loss of Eden, till one greater Man
Restore us, and regain the blissful Seat,
Sing Heav'nly Muse, that on the secret top
Of Oreb, or of Sinai, didst inspire
That Shepherd, who first taught the chosen Seed,
In the Beginning how the Heav'ns and Earth
Rose out of Chaos: or if Sion Hill
Delight thee more, and Siloa's brook that flow'd
Fast by the Oracle of God; I thence
Invoke thy aid to my adventrous Song,
That with no middle flight intends to soar
Above th' Aonian Mount, while it pursues
Things unattempted yet in Prose or Rhime.
And chiefly Thou, O Spirit, that dost prefer
Before all Temples th' upright heart and pure,
Instruct me, for Thou know'st; Thou from the first
Wast present, and with mighty wings outspread
Dove-like satst brooding on the vast Abyss
And mad'st it pregnant: What in me is dark
Illumin, what is low raise and support;
That to the highth of this great Argument
I may assert Eternal Providence,
And justifie the wayes of God to men.
Obtaining this:
OF Mans First Disobedience, and the Fruit
        Of that Forbidden Tree, whose mortal tast
        Brought Death into the World, and all our woe,
     4  With loss of Eden, till one greater Man
        Restore us, and regain the blissful Seat,
        Sing Heav'nly Muse, that on the secret top
        Of Oreb, or of Sinai, didst inspire
     8  That Shepherd, who first taught the chosen Seed,
        In the Beginning how the Heav'ns and Earth
        Rose out of Chaos: or if Sion Hill
        Delight thee more, and Siloa's brook that flow'd
    12  Fast by the Oracle of God; I thence
        Invoke thy aid to my adventrous Song,
        That with no middle flight intends to soar
        Above th' Aonian Mount, while it pursues
    16  Things unattempted yet in Prose or Rhime.
        And chiefly Thou, O Spirit, that dost prefer
        Before all Temples th' upright heart and pure,
        Instruct me, for Thou know'st; Thou from the first
    20  Wast present, and with mighty wings outspread
        Dove-like satst brooding on the vast Abyss
        And mad'st it pregnant: What in me is dark
        Illumin, what is low raise and support;
    24  That to the highth of this great Argument
        I may assert Eternal Providence,
        And justifie the wayes of God to men.
Can, awk, also indent lines in this way
OF Mans First Disobedience, and the Fruit
        Of that Forbidden Tree, whose mortal tast
          Brought Death into the World, and all our woe,
     4  With loss of Eden, till one greater Man
          Restore us, and regain the blissful Seat,
        Sing Heav'nly Muse, that on the secret top
          Of Oreb, or of Sinai, didst inspire
     8  That Shepherd, who first taught the chosen Seed,
And like this too?
OF Mans First Disobedience, and the Fruit
          Of that Forbidden Tree, whose mortal tast
        Brought Death into the World, and all our woe,
     4    With loss of Eden, till one greater Man
        Restore us, and regain the blissful Seat,
          Sing Heav'nly Muse, that on the secret top
        Of Oreb, or of Sinai, didst inspire
     8    That Shepherd, who first taught the chosen Seed,
Asked by Dingo (339 rep)
Dec 9, 2021, 12:53 AM
Last activity: Feb 8, 2022, 07:33 PM