You don't draw a line read the questions asked, pick the pline, pick the block, pick a point to draw the line & blocks and enter a gap distance between them say 1000. The line with copied blocks is automatically drawn. The line will be as long as there is blocks.
Here is the help for Extend it has some variables you can set may be applicable for Acad.
https://help.bricsys.com/en-us/document/command-reference/e/extend-command?version=V25&id=165079077042
@SLW210 it ask for the polyline where the blocks are inserted, then get the coordinates from such polyline , and use it to get all blocks as selectionset .
It draw a polyline straight long enough to receive the new block at a given distance, 1000 units in this cas
Then it copy each one and move to the new line
I use the acaddoc.lsp to set my Sysvars.
;(SETVAR "" n)
(SETVAR "FILEDIA" 1)
(SETVAR "FILLMODE" 1)
(SETVAR "FRAME" 2)
System variables are not saved in AutoCAD I just went through the SYSVDLG, then made the settings as I had them.
Not sure how up to date this list is...
List of System Variables - AutoCAD Tutorial and Videos