I find it really interesting that although the language seems to come from the Psalms, the usage varies. Nephi isn't strictly borrowing, he is using creative license to make his point while at the same time clearly making a reference to what I believe were well-known Hebrew hymns. If we think of the Psalms as serving the same function for the Israelites that the hymns serve for us today, this would be like someone paraphrasing a famous hymn lyric but changing it up. For example, if I said, "I stood all amazed when I noticed my dad left me a card." Or "he put his shoulder to the task and pushed along."
I don't exactly know what to make of this, except that I find it very interesting, and Joseph Smith would have needed to know all of the Psalms by heart to accomplish this without notes.
Give Ear To My Words
1 Give ear to my words, O Lord, consider my meditation. (Psalm 5)
40 O, my beloved brethren, give ear to my words. Remember the greatness of the Holy One of Israel. Do not say that I have spoken hard things against you; for if ye do, ye will revile against the truth; for I have spoken the words of your Maker. I know that the words of truth are hard against all uncleanness; but the righteous fear them not, for they love the truth and are not shaken. (2 Nephi 9)
In the Psalm, the writer is asking the Lord to "give ear." In 2 Nephi, Jacob asks his brethren to "give ear."
The Rock ... of Salvation
7 In God is my salvation and my glory: the rock of my strength, and my refuge, is in God. (Psalm 62)
26 He shall cry unto me, Thou art my father, my God, and the rock of my salvation. (Psalm 89)
1 O come, let us sing unto the Lord: let us make a joyful noise to the rock of our salvation. (Psalm 95)
45 O, my beloved brethren, turn away from your sins; shake off the chains of him that would bind you fast; come unto that God who is the rock of your salvation. (2 Nephi 9)
Clean Hands ... Pure Heart
4 He that hath clean hands, and a pure heart; who hath not lifted up his soul unto vanity, nor sworn deceitfully. (Psalm 24)
16 And after they have been scattered, and the Lord God hath scourged them by other nations for the space of many generations, yea, even down from generation to generation until they shall be persuaded to believe in Christ, the Son of God, and the atonement, which is infinite for all mankind—and when that day shall come that they shall believe in Christ, and worship the Father in his name, with pure hearts and clean hands, and look not forward any more for another Messiah, then, at that time, the day will come that it must needs be expedient that they should believe these things. (2 Nephi 25)
Shall Swallow Them Up
9 Thou shalt make them as a fiery oven in the time of thine anger: the Lord shall swallow them up in his wrath, and the fire shall devour them. (Psalm 21)
5 And they that kill the prophets, and the saints, the depths of the earth shall swallow them up, saith the Lord of Hosts; and mountains shall cover them, and whirlwinds shall carry them away, and buildings shall fall upon them and crush them to pieces and grind them to powder. (2 Nephi 26)
Notice that the Lord does the swallowing in the Psalm and the earth does the swallowing in 2 Nephi.
The Depths of the Earth
20 Thou, which hast shewed me great and sore troubles, shalt quicken me again, and shalt bring me up again from the depths of the earth. (Psalm 71)
5 And they that kill the prophets, and the saints, the depths of the earth shall swallow them up, saith the Lord of Hosts; and mountains shall cover them, and whirlwinds shall carry them away, and buildings shall fall upon them and crush them to pieces and grind them to powder. (2 Nephi 26)
The Wicked Will He Destroy
20 The Lord preserveth all them that love him: but all the wicked will he destroy. (Psalm 145)
10 For the time speedily cometh that the Lord God shall cause a great division among the people, and the wicked will he destroy; and he will spare his people, yea, even if it so be that he must destroy the wicked by fire. (2 Nephi 30)
Water ... By Night
6 I am weary with my groaning; all the night make I my bed to swim; I water my couch with my tears. (Psalm 6)
3 But I, Nephi, have written what I have written, and I esteem it as of great worth, and especially unto my people. For I pray continually for them by day, and mine eyes water my pillow by night, because of them; and I cry unto my God in faith, and I know that he will hear my cry. (2 Nephi 33)