Code:
tests-Mac:Desktop test$ $SHELL --version
GNU bash, version 3.2.57(1)-release (x86_64-apple-darwin17)
Copyright (C) 2007 Free Software Foundation, Inc.
tests-Mac:Desktop test$ uname -v
Darwin Kernel Version 17.7.0: Sun Jun 2 20:31:42 PDT 2019; root:xnu-4570.71.46~1/RELEASE_X86_64
tests-Mac:Desktop test$ sw_vers -productVersion
10.13.6
tests-Mac:Desktop test$ sed --version
sed: illegal option -- -
usage: sed script [-Ealn] [-i extension] [file ...]
sed [-Ealn] [-i extension] [-e script] ... [-f script_file] ... [file ...]
tests-Mac:Desktop test$ osascript -e 'tell application "System Events" to get properties of every login item' | sed 's/, name/\ name/g'
name:Mail, path:/Applications/Mail.app, class:login item, kind:Application, hidden:false name:DVD Player, path:/Applications/DVD Player.app, class:login item, kind:Application, hidden:true name:Calculator, path:/Applications/Calculator.app, class:login item, kind:Application, hidden:false name:Calendar, path:/Applications/Calendar.app, class:login item, kind:Application, hidden:false name:App Store, path:/Applications/App Store.app, class:login item, kind:Application, hidden:false
tests-Mac:Desktop test$ sed 's/, name/\nname/g' yourfile.txt
name:Pages, path:/Applications/Pages.app, class:login item, kind:Application, hidden:falsenname:Calculator, path:/System/Applications/Calculator.app, class:login item, kind:Application, hidden:truenname:Calendar, path:/System/Applications/Calendar.app, class:login item, kind:Application, hidden:false
tests-Mac:Desktop test$ osascript -e 'tell application "System Events" to get properties of every login item' | sed 's/, name/\nname/g'
name:Mail, path:/Applications/Mail.app, class:login item, kind:Application, hidden:falsenname:DVD Player, path:/Applications/DVD Player.app, class:login item, kind:Application, hidden:truenname:Calculator, path:/Applications/Calculator.app, class:login item, kind:Application, hidden:falsenname:Calendar, path:/Applications/Calendar.app, class:login item, kind:Application, hidden:falsenname:App Store, path:/Applications/App Store.app, class:login item, kind:Application, hidden:false