Here David is giving a command to all of the people of Israel. Alternate translation: "Now then, in the sight of all Israel, this assembly for Yahweh, and in the presence of our God, I command all of you to" (See: [[rc://en/ta/man/jit/figs-explicit]])
These two phrases have the same meaning and the second describes the first. Even though all of the people of Israel are not present, those present represent all of Israel. Alternate translation: "all you people of Israel, in this assembly for Yahweh" (See: [[rc://en/ta/man/jit/figs-parallelism]] and [[rc://en/ta/man/jit/figs-synecdoche]])
The phrase "in the sight of" means that they are all present and listening. Alternate translation: "in the hearing of" (See: [[rc://en/ta/man/jit/figs-idiom]])
The phrase "to carry out" means basically the same thing as "keep." Together the words emphasize importance of doing what God commands. Alternate translation: "carefully obey" (See: [[rc://en/ta/man/jit/figs-doublet]])
This means that the land will belong to their descendants in the future. The phrase "after you" is an idiom. Alternate translation: "your children and your descendants, who will take your place after you die" (See: [[rc://en/ta/man/jit/figs-synecdoche]] and [[rc://en/ta/man/jit/figs-idiom]])