א בִּנְיָן, אֲפִלּוּ כָּל שֶׁהוּא, אָסוּר; וְאִם נִפְרַץ גֶּדֶר גִּנָּתוֹ אוֹ כֹּתֶל חֲצֵרוֹ שֶׁבֵּינוֹ לַחֲבֵרוֹ (מָרְדְּכַי פ"ק דמ"ק וְהַגָּהוֹת מַיְמוֹנִי פ"ח), בּוֹנֶהוּ מַעֲשֵׂה הֶדְיוֹט דְּהַיְנוּ שֶׁמַּנִּיחַ אֲבָנִים זוֹ עַל זוֹ וְאֵינוֹ טָח בַּטִּיט; אוֹ גּוֹדֵר אוֹתוֹ בְּקָנִים וְגוּמָא וְכַיּוֹצֵא בָּהֶם. וְכֵן אִם עָשָׂה מַעֲקֶה לַגַּג, בּוֹנֶה אוֹתוֹ מַעֲשֵׂה הֶדְיוֹט; אֲבָל כֹּתֶל חָצֵר הַסָמוּךְ לִרְשׁוּת הָרַבִּים שֶׁנָּפַל, בּוֹנֶהוּ כְּדַרְכּוֹ; וְאִם הָיָה נוֹטֶה לִפֹּל, סוֹתְרוֹ מִפְּנֵי הַסַכָּנָה וּבוֹנֶה כְּדַרְכּוֹ. הַגָּה: וַאֲפִלּוּ אֵינוֹ נוֹטֶה רַק לֶחָצֵר אוֹ לַמָּבוֹי, מֻתָּר לְסָתְרוֹ מִפְּנֵי הַסַּכָּנָה וְלַחֲזֹר וְלִבְנוֹתוֹ; וְכֵן בִּשְׁאָר דְּבָרִים דְּאִיכָּא לְמֵיחַשׁ לְסַכָּנָה, בּוֹנֶה וְסוֹתְרוֹ כְּדַרְכּוֹ (בֵּית יוֹסֵף בְּשֵׁם רַבֵּנוּ יְרוּחָם בנ"י).
1 Laws of Building and Demolishing on Chol HaMoed, in it is 8 paragraphs. Building even a bit is forbidden. If there was a breach in the fence of his orchard [or the wall of his courtyard that is between him and his friend - (Mordechai, 1st Chapter of Moed Katan & Hagaaos Maimoni Chapter 8], build an act of an amateur that is place rocks on top of each other or plaster mud or fence (the breach) with reeds, papyrus, and like those. Similarly, if making a railing for a roof, build in an act of an amateur; however, if building a wall for his courtyard that is near the public thoroughfare that fell, build as normal, and if it is leaning to fall, demolish because of danger and build normally. Rema: Even if it is only leaning to the courtyard or alley, it is allowed to demolish because of danger and return and rebuild. Similar with other matters that there is a concern of danger, build and demolish as usual (Bais Yosef in the name of Reb Yerucham BN'Y)